File tree Expand file tree Collapse file tree
src/test/java/org/rest/persistence Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11<?xml version =" 1.0" encoding =" UTF-8" standalone =" no" ?>
22<launchConfiguration type =" org.eclipse.jdt.junit.launchconfig" >
33<listAttribute key =" org.eclipse.debug.core.MAPPED_RESOURCE_PATHS" >
4- <listEntry value =" /rest/src/test/java/org/rest/sec/persistence/service/RoleServicePersistenceIntegrationTest .java" />
4+ <listEntry value =" /rest/src/test/java/org/rest/test/suite/IntegrationPersistenceTestSuite .java" />
55</listAttribute >
66<listAttribute key =" org.eclipse.debug.core.MAPPED_RESOURCE_TYPES" >
77<listEntry value =" 1" />
1515<stringAttribute key =" org.eclipse.jdt.junit.TESTNAME" value =" " />
1616<stringAttribute key =" org.eclipse.jdt.junit.TEST_KIND" value =" org.eclipse.jdt.junit.loader.junit4" />
1717<stringAttribute key =" org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value =" org.eclipse.m2e.launchconfig.classpathProvider" />
18- <stringAttribute key =" org.eclipse.jdt.launching.MAIN_TYPE" value =" org.rest.sec.persistence.service.RoleServicePersistenceIntegrationTest " />
18+ <stringAttribute key =" org.eclipse.jdt.launching.MAIN_TYPE" value =" org.rest.test.suite.IntegrationPersistenceTestSuite " />
1919<stringAttribute key =" org.eclipse.jdt.launching.PROJECT_ATTR" value =" rest" />
2020<stringAttribute key =" org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value =" org.eclipse.m2e.launchconfig.sourcepathProvider" />
2121</launchConfiguration >
Original file line number Diff line number Diff line change @@ -177,37 +177,9 @@ public void givenEntityExists_whenEntityIsDeleted_thenEntityIsNoLongerRetrievabl
177177 }
178178
179179 // delete all
180+ // - note: the goal of these tests is to be independent of each other; because of this, deleteAll is not an option
180181
181- @ Test
182- public void givenEntityExists_whenEntitiesAreDeleted_thenNoException (){
183- // Given
184- this .getAPI ().save ( this .createNewEntity () );
185-
186- // When
187- getAPI ().deleteAll ();
188- }
189- @ Test
190- public void givenNoEntityExists_whenEntitiesAreDeleted_thenNoException (){
191- // Given
192- getAPI ().deleteAll ();
193-
194- // When
195- getAPI ().deleteAll ();
196- }
197-
198- @ Test
199- public void givenEntityExists_whenEntitiesAreDeleted_thenEntitiesNoLongerRetrievable (){
200- // Given
201- getAPI ().save ( createNewEntity () );
202-
203- // When
204- getAPI ().deleteAll ();
205-
206- // Then
207- assert ( getAPI ().findAll ().size () == 0 );
208- }
209-
210- //
182+ // template method
211183
212184 protected abstract JpaRepository < T , Long > getAPI ();
213185
You can’t perform that action at this time.
0 commit comments