[augeas-devel] [Augeas] #244: test save fail

Augeas trac at fedorahosted.org
Fri Dec 23 17:47:45 UTC 2011


#244: test save fail
------------------------+----------------------
 Reporter:  fgiraldeau  |       Owner:  raphink
     Type:  defect      |      Status:  new
 Priority:  major       |   Milestone:  next
Component:  Augeas      |     Version:  devel
 Keywords:              |  Blocked By:
 Blocking:              |
------------------------+----------------------
 test-save raise an error since yum lens has been changed:

 {{{
 FAIL: test-save (exit: 1)
 =========================

 F....

 There was 1 failure:
 1) testSaveNewFile:
 test-save.c:82: expected <0> but was <-1>

 }}}

 Steps to reproduce the problem:
 {{{
 [francis at blob augeas]$ ./src/augtool -I lenses/ --root tests/root/
 augtool> set /files/etc/yum.repos.d/new.repo/newrepo/baseurl
 http://foo.com/
 augtool> save
 error: Failed to execute command
 saving failed (run 'print /augeas//error' for details)
 augtool> print /augeas//error
 /augeas/files/etc/yum.repos.d/new.repo/error = "put_failed"
 /augeas/files/etc/yum.repos.d/new.repo/error/pos = "1"
 /augeas/files/etc/yum.repos.d/new.repo/error/lens =
 "lenses/yum.aug:49.13-.20:"
 /augeas/files/etc/yum.repos.d/new.repo/error/message = "Iterated lens
 matched less than it should"
 }}}

 The same commands in a unittest works:
 {{{
 module Test_yum_bug =
 test Yum.lns put "" after set "/test/baseurl" "http://example.com" =
 "[test]
 baseurl=http://example.com
 "
 }}}

 Weird?

-- 
Ticket URL: <https://fedorahosted.org/augeas/ticket/244>
Augeas <http://augeas.net/>
a configuration API




More information about the augeas-devel mailing list