-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#1 Refactor and add support for pending, throwing and undefined tests
- Loading branch information
Showing
8 changed files
with
264 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,50 +1,62 @@ | ||
##teamcity[testSuiteStarted name='A passing test'] | ||
##teamcity[testStarted name='Before ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Before ' duration='990'] | ||
##teamcity[testFinished name='Before ' duration='747'] | ||
##teamcity[testStarted name='Given something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Given something' duration='411'] | ||
##teamcity[testFinished name='Given something' duration='790'] | ||
##teamcity[testStarted name='When something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='When something' duration='934'] | ||
##teamcity[testFinished name='When something' duration='123'] | ||
##teamcity[testStarted name='Then the test should pass' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Then the test should pass' duration='666'] | ||
##teamcity[testStarted name='After ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='After ' duration='45'] | ||
##teamcity[testFinished name='After ' duration='894'] | ||
##teamcity[testSuiteFinished name='A passing test'] | ||
##teamcity[testSuiteStarted name='A failing test'] | ||
##teamcity[testStarted name='Before ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Before ' duration='220'] | ||
##teamcity[testFinished name='Before ' duration='162'] | ||
##teamcity[testStarted name='Given something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Given something' duration='238'] | ||
##teamcity[testFinished name='Given something' duration='671'] | ||
##teamcity[testStarted name='When something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='When something' duration='729'] | ||
##teamcity[testFinished name='When something' duration='49'] | ||
##teamcity[testStarted name='Then the test should fail' captureStandardOutput='false'] | ||
##teamcity[testFailed name='ScenarioA failing test' message='AssertionError: expected true to equal false' details='|n at World.<anonymous> (C:\Git\oledid\cucumber-json-to-teamcity\features\resources\mock.feature.steps.js:26:21)|n at nextTickCallbackWith0Args (node.js:420:9)|n at process._tickCallback (node.js:349:13)|n at Function.Module.runMain (modul'] | ||
##teamcity[testFinished name='Then the test should fail' duration='783'] | ||
##teamcity[testFinished name='Then the test should fail' duration='665'] | ||
##teamcity[testStarted name='After ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='After ' duration='237'] | ||
##teamcity[testFinished name='After ' duration='275'] | ||
##teamcity[testSuiteFinished name='A failing test'] | ||
##teamcity[testSuiteStarted name='A pending test'] | ||
##teamcity[testStarted name='Before ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Before ' duration='427'] | ||
##teamcity[testFinished name='Before ' duration='936'] | ||
##teamcity[testStarted name='Given something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Given something' duration='162'] | ||
##teamcity[testFinished name='Given something' duration='708'] | ||
##teamcity[testStarted name='When something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='When something' duration='823'] | ||
##teamcity[testFinished name='When something' duration='973'] | ||
##teamcity[testStarted name='Then the test should be ignored' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Then the test should be ignored' duration='NaN'] | ||
##teamcity[testStarted name='After ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='After ' duration='521'] | ||
##teamcity[testFinished name='After ' duration='12'] | ||
##teamcity[testSuiteFinished name='A pending test'] | ||
##teamcity[testSuiteStarted name='A test that throws an error'] | ||
##teamcity[testStarted name='Before ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Before ' duration='521'] | ||
##teamcity[testFinished name='Before ' duration='464'] | ||
##teamcity[testStarted name='Given something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Given something' duration='502'] | ||
##teamcity[testFinished name='Given something' duration='819'] | ||
##teamcity[testStarted name='When something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='When something' duration='860'] | ||
##teamcity[testFinished name='When something' duration='407'] | ||
##teamcity[testStarted name='Then the test should throw an error' captureStandardOutput='false'] | ||
##teamcity[testFailed name='ScenarioA test that throws an error' message='Error: I am an error' details='|n at World.<anonymous> (C:\Git\oledid\cucumber-json-to-teamcity\features\resources\mock.feature.steps.js:33:11)|n at nextTickCallbackWith0Args (node.js:420:9)|n at process._tickCallback (node.js:349:13)|n at Function.Module.runMain (module.js:443:11)|n at star'] | ||
##teamcity[testFinished name='Then the test should throw an error' duration='141'] | ||
##teamcity[testFinished name='Then the test should throw an error' duration='290'] | ||
##teamcity[testStarted name='After ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='After ' duration='49'] | ||
##teamcity[testSuiteFinished name='A test that throws an error'] | ||
##teamcity[testSuiteStarted name='An undefined test'] | ||
##teamcity[testStarted name='Before ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Before ' duration='427'] | ||
##teamcity[testStarted name='Given something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Given something' duration='483'] | ||
##teamcity[testStarted name='When something' captureStandardOutput='false'] | ||
##teamcity[testFinished name='When something' duration='180'] | ||
##teamcity[testStarted name='Then the test is not defined' captureStandardOutput='false'] | ||
##teamcity[testFinished name='Then the test is not defined' duration='NaN'] | ||
##teamcity[testStarted name='After ' captureStandardOutput='false'] | ||
##teamcity[testFinished name='After ' duration='427'] | ||
##teamcity[testSuiteFinished name='A test that throws an error'] | ||
##teamcity[testFinished name='After ' duration='841'] | ||
##teamcity[testSuiteFinished name='An undefined test'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,7 +37,5 @@ module.exports = function () { | |
callback(null, "pending"); | ||
} | ||
} | ||
|
||
return null; | ||
}); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
Feature: Test states | ||
As a developer using TeamCity | ||
I want to make sure that I can read the correct test states from TeamCity | ||
|
||
Scenario: A passing test | ||
Given a passing test | ||
When I have translated it with this API | ||
Then TeamCity should be able to see that it is a passing test | ||
|
||
Scenario: A failing test | ||
Given a failing test | ||
When I have translated it with this API | ||
Then TeamCity should be able to see that it is a failing test | ||
|
||
Scenario: A pending test | ||
Given a pending test | ||
When I have translated it with this API | ||
Then TeamCity should be able to see that it is a pending test | ||
|
||
Scenario: A test that throws an error | ||
Given a test that throws an error | ||
When I have translated it with this API | ||
Then TeamCity should be able to see that it is a test that throws an error | ||
|
||
Scenario: An undefined test | ||
Given an undefined test | ||
When I have translated it with this API | ||
Then TeamCity should be able to see that it is an undefined test |
Oops, something went wrong.