[SPR-5889] Renaming TestNG tests from *Tests_ back to *Tests, but keeping @org.junit.Ignore to exclude them from the JUnit test run.
git-svn-id: https://src.springframework.org/svn/spring-framework/trunk@1463 50f2f4bb-b051-0410-bef5-90022cba6387
This commit is contained in:
parent
aef72ba508
commit
5d53a1845b
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2007 the original author or authors.
|
||||
* Copyright 2002-2009 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
|
@ -26,7 +26,6 @@ import static org.testng.Assert.assertTrue;
|
|||
import javax.annotation.Resource;
|
||||
import javax.sql.DataSource;
|
||||
|
||||
import org.junit.Ignore;
|
||||
import org.springframework.beans.Employee;
|
||||
import org.springframework.beans.Pet;
|
||||
import org.springframework.beans.factory.BeanNameAware;
|
||||
|
|
@ -52,31 +51,21 @@ import org.testng.annotations.Test;
|
|||
* @author Sam Brannen
|
||||
* @since 2.5
|
||||
*/
|
||||
@Ignore // renamed to Tests_ to avoid being picked up by junit. Spring Build support for TestNG is pending.
|
||||
@org.junit.Ignore("TestNG tests should not be run by JUnit")
|
||||
@ContextConfiguration
|
||||
public class ConcreteTransactionalTestNGSpringContextTests_ extends AbstractTransactionalTestNGSpringContextTests
|
||||
public class ConcreteTransactionalTestNGSpringContextTests extends AbstractTransactionalTestNGSpringContextTests
|
||||
implements BeanNameAware, InitializingBean {
|
||||
|
||||
// ------------------------------------------------------------------------|
|
||||
// --- CONSTANTS ----------------------------------------------------------|
|
||||
// ------------------------------------------------------------------------|
|
||||
|
||||
private static final String BOB = "bob";
|
||||
private static final String JANE = "jane";
|
||||
private static final String SUE = "sue";
|
||||
private static final String YODA = "yoda";
|
||||
|
||||
// ------------------------------------------------------------------------|
|
||||
// --- STATIC VARIABLES ---------------------------------------------------|
|
||||
// ------------------------------------------------------------------------|
|
||||
|
||||
private static int numSetUpCalls = 0;
|
||||
private static int numSetUpCallsInTransaction = 0;
|
||||
private static int numTearDownCalls = 0;
|
||||
private static int numTearDownCallsInTransaction = 0;
|
||||
|
||||
// ------------------------------------------------------------------------|
|
||||
// --- INSTANCE VARIABLES -------------------------------------------------|
|
||||
// ------------------------------------------------------------------------|
|
||||
|
||||
private boolean beanInitialized = false;
|
||||
|
|
@ -97,8 +86,6 @@ public class ConcreteTransactionalTestNGSpringContextTests_ extends AbstractTran
|
|||
protected String bar;
|
||||
|
||||
|
||||
// ------------------------------------------------------------------------|
|
||||
// --- STATIC METHODS -----------------------------------------------------|
|
||||
// ------------------------------------------------------------------------|
|
||||
|
||||
private static int clearPersonTable(SimpleJdbcTemplate simpleJdbcTemplate) {
|
||||
|
|
@ -126,8 +113,6 @@ public class ConcreteTransactionalTestNGSpringContextTests_ extends AbstractTran
|
|||
return simpleJdbcTemplate.update("DELETE FROM person WHERE name=?", name);
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------------|
|
||||
// --- INSTANCE METHODS ---------------------------------------------------|
|
||||
// ------------------------------------------------------------------------|
|
||||
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
|
|
@ -275,8 +260,6 @@ public class ConcreteTransactionalTestNGSpringContextTests_ extends AbstractTran
|
|||
}
|
||||
|
||||
|
||||
// ------------------------------------------------------------------------|
|
||||
// --- TYPES --------------------------------------------------------------|
|
||||
// ------------------------------------------------------------------------|
|
||||
|
||||
public static class DatabaseSetup {
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2007 the original author or authors.
|
||||
* Copyright 2002-2009 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
|
@ -21,7 +21,6 @@ import static org.testng.Assert.assertNotNull;
|
|||
import static org.testng.Assert.assertNotSame;
|
||||
import static org.testng.Assert.assertSame;
|
||||
|
||||
import org.junit.Ignore;
|
||||
import org.springframework.context.ApplicationContext;
|
||||
import org.springframework.test.annotation.DirtiesContext;
|
||||
import org.springframework.test.context.ContextConfiguration;
|
||||
|
|
@ -48,9 +47,9 @@ import org.testng.annotations.Test;
|
|||
* @author Sam Brannen
|
||||
* @since 2.5
|
||||
*/
|
||||
@Ignore // renamed to Tests_ to avoid being picked up by junit. Spring Build support for TestNG is pending.
|
||||
@org.junit.Ignore("TestNG tests should not be run by JUnit")
|
||||
@ContextConfiguration
|
||||
public class DirtiesContextTransactionalTestNGSpringContextTests_ extends AbstractTransactionalTestNGSpringContextTests {
|
||||
public class DirtiesContextTransactionalTestNGSpringContextTests extends AbstractTransactionalTestNGSpringContextTests {
|
||||
|
||||
private ApplicationContext dirtiedApplicationContext;
|
||||
|
||||
Loading…
Reference in New Issue