Skip to content

Commit

Permalink
[ci] rails 5: Fix invalid css syntax when parsing xml
Browse files Browse the repository at this point in the history
This was causing errors during test runs:

Nokogiri::CSS::SyntaxError:         Nokogiri::CSS::SyntaxError: unexpected 'text(' after 'not('
            test/functional/webui/project_controller_test.rb:398:in `block in test_save_meta'
            test/functional/webui/project_controller_test.rb:396:in `test_save_meta'
            test/test_helper.rb:124:in `block in __run'
            test/test_helper.rb:124:in `map'
            test/test_helper.rb:124:in `__run'
  • Loading branch information
bgeuken committed Jul 19, 2016
1 parent 75282e2 commit 11cca9a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/api/test/functional/webui/project_controller_test.rb
Expand Up @@ -372,7 +372,7 @@ def test_save_meta
result = Nokogiri::XML(meta_xml)
assert_select result, "project", name: "home:adrian" do
assert_select "title", "My Home Project", 1
assert_select "description[not(text())]", 1, "Should have an empty description"
assert_select "description", { count: 1, text: "" }, "Should have an empty description"
assert_select "person", userid: "adrian", role: "maintainer"
end
assert_equal 3, result.xpath("/project/child::*").count, "Should not have additional nodes."
Expand All @@ -395,7 +395,7 @@ def test_save_meta
result = Nokogiri::XML(meta_xml)
assert_select result, "project", name: "home:adrian" do
assert_select "title", "My Home Project", 1
assert_select "description[not(text())]", 1, "Should have an empty description"
assert_select "description", { count: 1, text: "" }, "Should have an empty description"
assert_select "person", userid: "adrian", role: "maintainer"
end
assert_equal 3, result.xpath("/project/child::*").count, "Should not have additional nodes."
Expand Down

0 comments on commit 11cca9a

Please sign in to comment.