Tomas Volf <~@wolfsden.cz> writes: > Honestly this is just under-specified in the SRFI-64. The full wording > of description for test-runner-test-name is: > >> Returns the name of the current test or test group, as a >> string. During execution of test-begin this is the name of the test >> group; during the execution of an actual test, this is the name of the >> test-case. If no name was specified, the name is the empty string. > > Both your calls to `show-name' are done neither during "execution of > test-begin" nor during "execution of an actual test". My reading of the > specification is that the behavior here is undefined. But in the spirit > of the behavior of test result properties, it made sense to me to leave > the last valid value in there. > > Maybe I am missing something.
Oh, well I wasn't sure what was expected/desirable -- I'd just leaned toward the more "nested" approach, likely in part because as mentioned, I was looking at SRFI-64 while pondering its relationship to (test-suite lib), given Maxim's suggestion that we might want to consider implementing (test-suite lib) in terms of SRFI-64. And to do that, *if* we consider the test-suite API to be part of Guile's stable API, we'd need to implement the public with-test-prefix... set, current-test-prefix etc. in a backward compatible way, or wait for a release where we can break compatibility. In the test-suite, via with-test-prefix*, there's always a list of nested prefixes in prefix-fluid, with a test name at the end *only* while the test body is running, and so I was contemplating whether you might implement a compatible enough (current-test-prefix) in terms of test-runner-group*, test-runner-test-name, etc. That's why I was thinking about it, but then it also seems like the other "extended" features of the current test suite (throwing fail, unresolved, etc.) are the more notable concern anyway. -- Rob Browning rlb @defaultvalue.org and @debian.org GPG as of 2011-07-10 E6A9 DA3C C9FD 1FF8 C676 D2C4 C0F0 39E9 ED1B 597A GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4