Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

testcase elements don't have 'name' attribute for dynamically generated rspec examples #6

Closed
justfalter opened this issue Jun 11, 2010 · 1 comment

Comments

@justfalter
Copy link
Contributor

When handling dynamically generated rspec examples, ci_reporter generates elements without the 'name' attribute. This screws up Hudson's JUnit parsing.

When handling an rspec like this:

describe 12345 do
subject {12345}
it {should eql(12345)}
its(:to_i) {should eql(12345)}
it "should bla"
end

I the testcase elements don't reliably have names:

I dug into it, and it's because of how ci/reporter/rspec.rb gets the example name. In cases where the example name is dynamically generated, the Spec::Example::ExampleProxy#description is nil in example_started, and doesn't get it's description set until example_failed, example_passed, example_pending.
As a result, the XML that's output is missing the name attribute, since it is nil.

@nicksieger
Copy link
Member

Should be fixed in f0f0966.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants