Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tristan Cavelier
slapos
Commits
eb925633
Commit
eb925633
authored
Aug 09, 2018
by
Xiaowu Zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jstestnode: get correct test result when global failure occur
parent
18db2316
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
5 deletions
+10
-5
software/jstestnode/runTestSuite.in
software/jstestnode/runTestSuite.in
+9
-4
software/jstestnode/software.cfg
software/jstestnode/software.cfg
+1
-1
No files found.
software/jstestnode/runTestSuite.in
View file @
eb925633
...
@@ -146,10 +146,15 @@ def main():
...
@@ -146,10 +146,15 @@ def main():
print ' '.join(body.xpath('//*[@id="qunit-testresult"]//text()'))
print ' '.join(body.xpath('//*[@id="qunit-testresult"]//text()'))
for elt in body.xpath('.//ol[@id="qunit-tests"]/li'):
for elt in body.xpath('.//ol[@id="qunit-tests"]/li'):
if (len(elt.xpath('.//span[@class="module-name"]'))):
test_name = '%s: %s' % (
test_name = '%s: %s' % (
elt.xpath('.//span[@class="module-name"]')[0].text,
elt.xpath('.//span[@class="module-name"]')[0].text,
elt.xpath('.//span[@class="test-name"]')[0].text
elt.xpath('.//span[@class="test-name"]')[0].text
)
)
#global failure, like Uncaught ReferenceError: RSVP is not defined
else:
test_name = elt.xpath('.//span[@class="test-name"]')[0].text
print elt.get('class'), ''.join(elt.xpath('.//strong')[0].itertext())
print elt.get('class'), ''.join(elt.xpath('.//strong')[0].itertext())
# print elt.find_element_by_tag_name('ol').get_attribute('innerHTML')
# print elt.find_element_by_tag_name('ol').get_attribute('innerHTML')
...
...
software/jstestnode/software.cfg
View file @
eb925633
...
@@ -107,7 +107,7 @@ mode = 0644
...
@@ -107,7 +107,7 @@ mode = 0644
[template-runTestSuite]
[template-runTestSuite]
recipe = slapos.recipe.template
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/runTestSuite.in
url = ${:_profile_base_location_}/runTestSuite.in
md5sum =
0a918eb070d28abfd33e0fcca26569ff
md5sum =
a9544fa355e5da10fc20d7c927e4df07
output = ${buildout:directory}/runTestSuite.in
output = ${buildout:directory}/runTestSuite.in
mode = 0644
mode = 0644
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment