-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #271 from Xceptance/develop
5.0.1 release
- Loading branch information
Showing
8 changed files
with
78 additions
and
151 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
28 changes: 28 additions & 0 deletions
28
...st/java/com/xceptance/neodymium/junit4/testclasses/data/ClearedContextBetweenMethods.java
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 @@ | ||
package com.xceptance.neodymium.junit4.testclasses.data; | ||
|
||
import org.junit.Assert; | ||
import org.junit.Test; | ||
import org.junit.runner.RunWith; | ||
|
||
import com.xceptance.neodymium.junit4.NeodymiumRunner; | ||
import com.xceptance.neodymium.util.DataUtils; | ||
|
||
@RunWith(NeodymiumRunner.class) | ||
public class ClearedContextBetweenMethods | ||
{ | ||
@Test | ||
public void test() | ||
{ | ||
if (DataUtils.asString("testId").equals("fist set")) | ||
{ | ||
Assert.assertEquals("Test data is not matching the test expectations", "val1", DataUtils.asString("key1")); | ||
Assert.assertEquals("Test data is not matching the test expectations", "val2", DataUtils.asString("key2")); | ||
} | ||
else | ||
{ | ||
Assert.assertEquals("Test data is not overwritten", "new val", DataUtils.asString("key1")); | ||
Assert.assertNull("Test data context is not cleared", DataUtils.asString("key2", null)); | ||
} | ||
} | ||
|
||
} |
25 changes: 25 additions & 0 deletions
25
...st/java/com/xceptance/neodymium/junit5/testclasses/data/CleanedContextBetweenMethods.java
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,25 @@ | ||
package com.xceptance.neodymium.junit5.testclasses.data; | ||
|
||
import org.junit.Assert; | ||
|
||
import com.xceptance.neodymium.junit5.NeodymiumTest; | ||
import com.xceptance.neodymium.util.DataUtils; | ||
|
||
public class CleanedContextBetweenMethods | ||
{ | ||
@NeodymiumTest | ||
public void test() | ||
{ | ||
if (DataUtils.asString("testId").equals("fist set")) | ||
{ | ||
Assert.assertEquals("Test data is not matching the test expectations", "val1", DataUtils.asString("key1")); | ||
Assert.assertEquals("Test data is not matching the test expectations", "val2", DataUtils.asString("key2")); | ||
} | ||
else | ||
{ | ||
Assert.assertEquals("Test data is not overwritten", "new val", DataUtils.asString("key1")); | ||
Assert.assertNull("Test data context is not cleared", DataUtils.asString("key2", null)); | ||
} | ||
} | ||
|
||
} |
11 changes: 11 additions & 0 deletions
11
...sources/com/xceptance/neodymium/junit4/testclasses/data/CleanedContextBetweenMethods.json
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,11 @@ | ||
[ | ||
{ | ||
"testId": "fist set", | ||
"key1": "val1", | ||
"key2": "val2" | ||
}, | ||
{ | ||
"testId": "second set", | ||
"key1": "new val" | ||
} | ||
] |
11 changes: 11 additions & 0 deletions
11
...sources/com/xceptance/neodymium/junit5/testclasses/data/CleanedContextBetweenMethods.json
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,11 @@ | ||
[ | ||
{ | ||
"testId": "fist set", | ||
"key1": "val1", | ||
"key2": "val2" | ||
}, | ||
{ | ||
"testId": "second set", | ||
"key1": "new val" | ||
} | ||
] |