This is an automated email from the git hooks/post-receive script. eugene-guest pushed a commit to annotated tag OpenBSD in repository testng.
commit af1f910c8eb43d3db01704ec311c7ab368cc45c1 Author: Julien Herr <[email protected]> Date: Wed Apr 29 10:50:21 2015 +0200 Fix #93 --- .../InvokedMethodListenerTest.java | 17 ++++++++++------- src/test/java/test/invokedmethodlistener/Sample.java | 4 ++++ 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/src/test/java/test/invokedmethodlistener/InvokedMethodListenerTest.java b/src/test/java/test/invokedmethodlistener/InvokedMethodListenerTest.java index f6580c1..e687aef 100644 --- a/src/test/java/test/invokedmethodlistener/InvokedMethodListenerTest.java +++ b/src/test/java/test/invokedmethodlistener/InvokedMethodListenerTest.java @@ -49,8 +49,9 @@ public class InvokedMethodListenerTest extends SimpleBaseTest { /** * Fix for: - * http://code.google.com/p/testng/issues/detail?id=7 - * http://code.google.com/p/testng/issues/detail?id=86 + * https://github.com/juherr/testng-googlecode/issues/7 + * https://github.com/juherr/testng-googlecode/issues/86 + * https://github.com/cbeust/testng/issues/93 */ @Test public void sameMethodInvokedMultipleTimesShouldHaveDifferentTimeStamps() { @@ -58,13 +59,15 @@ public class InvokedMethodListenerTest extends SimpleBaseTest { tng.addListener(new InvokedMethodListener()); tng.run(); List<IInvokedMethod> m = InvokedMethodListener.m_methods; -// for (IInvokedMethod mm : m) { -// System.out.println(mm.getTestMethod().getMethodName() + " " + mm.getDate()); -// } - IInvokedMethod after1 = m.get(1); + IInvokedMethod beforeSuite = m.get(0); + Assert.assertFalse(beforeSuite.getTestMethod().isAfterMethodConfiguration()); + Assert.assertTrue(beforeSuite.isConfigurationMethod()); + IInvokedMethod after1 = m.get(2); Assert.assertTrue(after1.getTestMethod().isAfterMethodConfiguration()); - IInvokedMethod after2 = m.get(3); + Assert.assertTrue(after1.isConfigurationMethod()); + IInvokedMethod after2 = m.get(4); Assert.assertTrue(after2.getTestMethod().isAfterMethodConfiguration()); + Assert.assertTrue(after2.isConfigurationMethod()); Assert.assertTrue(after1.getDate() != after2.getDate()); } diff --git a/src/test/java/test/invokedmethodlistener/Sample.java b/src/test/java/test/invokedmethodlistener/Sample.java index 591865b..10a48ff 100644 --- a/src/test/java/test/invokedmethodlistener/Sample.java +++ b/src/test/java/test/invokedmethodlistener/Sample.java @@ -1,6 +1,7 @@ package test.invokedmethodlistener; import org.testng.annotations.AfterMethod; +import org.testng.annotations.BeforeSuite; import org.testng.annotations.Test; public class Sample { @@ -25,4 +26,7 @@ public class Sample { @AfterMethod public void am() {} + + @BeforeSuite + public void bs() {} } -- Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/testng.git _______________________________________________ pkg-java-commits mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-java-commits

