Search in sources :

Example 46 with Account_Condition

use of indi.mybatis.flying.pojo.condition.Account_Condition in project mybatis.flying by limeng32.

the class BatchProcessTest method testBatchUpdate10.

@Test
@DatabaseSetup(type = DatabaseOperation.CLEAN_INSERT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate10.xml")
@ExpectedDatabase(assertionMode = DatabaseAssertionMode.NON_STRICT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate10.result.xml")
@DatabaseTearDown(type = DatabaseOperation.DELETE_ALL, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate10.xml")
public void testBatchUpdate10() {
    Account_Condition ac = new Account_Condition();
    ac.setEmail("ann@tom.com");
    ac.setNameIsNull(true);
    accountService.update(ac);
    Account_Condition ac2 = new Account_Condition();
    ac2.setEmail("bob@tom.com");
    ac2.setNameIsNull(false);
    ac2.setActivateValueEqual("aaa");
    accountService.update(ac2);
}
Also used : Account_Condition(indi.mybatis.flying.pojo.condition.Account_Condition) ExpectedDatabase(com.github.springtestdbunit.annotation.ExpectedDatabase) Test(org.junit.Test) SpringBootTest(org.springframework.boot.test.context.SpringBootTest) DatabaseSetup(com.github.springtestdbunit.annotation.DatabaseSetup) DatabaseTearDown(com.github.springtestdbunit.annotation.DatabaseTearDown)

Example 47 with Account_Condition

use of indi.mybatis.flying.pojo.condition.Account_Condition in project mybatis.flying by limeng32.

the class BatchProcessTest method testBatchUpdate6.

@Test
@DatabaseSetup(type = DatabaseOperation.CLEAN_INSERT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate6.xml")
@ExpectedDatabase(assertionMode = DatabaseAssertionMode.NON_STRICT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate6.result.xml")
@DatabaseTearDown(type = DatabaseOperation.DELETE_ALL, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate6.xml")
public void testBatchUpdate6() {
    Account_Condition ac = new Account_Condition();
    ac.setEmail("ann@tom.com");
    ac.setNameLike("a");
    accountService.update(ac);
}
Also used : Account_Condition(indi.mybatis.flying.pojo.condition.Account_Condition) ExpectedDatabase(com.github.springtestdbunit.annotation.ExpectedDatabase) Test(org.junit.Test) SpringBootTest(org.springframework.boot.test.context.SpringBootTest) DatabaseSetup(com.github.springtestdbunit.annotation.DatabaseSetup) DatabaseTearDown(com.github.springtestdbunit.annotation.DatabaseTearDown)

Example 48 with Account_Condition

use of indi.mybatis.flying.pojo.condition.Account_Condition in project mybatis.flying by limeng32.

the class BatchProcessTest method testBatchDelete4.

@Test
@DatabaseSetup(type = DatabaseOperation.CLEAN_INSERT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchDelete4.xml")
@ExpectedDatabase(assertionMode = DatabaseAssertionMode.NON_STRICT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchDelete4.result.xml")
@DatabaseTearDown(type = DatabaseOperation.DELETE_ALL, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchDelete4.xml")
public void testBatchDelete4() {
    Account_Condition ac = new Account_Condition();
    ac.setNameIsNull(true);
    accountService.delete(ac);
}
Also used : Account_Condition(indi.mybatis.flying.pojo.condition.Account_Condition) ExpectedDatabase(com.github.springtestdbunit.annotation.ExpectedDatabase) Test(org.junit.Test) SpringBootTest(org.springframework.boot.test.context.SpringBootTest) DatabaseSetup(com.github.springtestdbunit.annotation.DatabaseSetup) DatabaseTearDown(com.github.springtestdbunit.annotation.DatabaseTearDown)

Example 49 with Account_Condition

use of indi.mybatis.flying.pojo.condition.Account_Condition in project mybatis.flying by limeng32.

the class BatchProcessTest method testBatchDelete5.

@Test
@DatabaseSetup(type = DatabaseOperation.CLEAN_INSERT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchDelete5.xml")
@ExpectedDatabase(assertionMode = DatabaseAssertionMode.NON_STRICT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchDelete5.result.xml")
@DatabaseTearDown(type = DatabaseOperation.DELETE_ALL, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchDelete5.xml")
public void testBatchDelete5() {
    List<String> nameC = new ArrayList<>();
    nameC.add("a2");
    nameC.add("b");
    Account_Condition ac = new Account_Condition();
    ac.setNameIn(nameC);
    accountService.delete(ac);
}
Also used : ArrayList(java.util.ArrayList) Account_Condition(indi.mybatis.flying.pojo.condition.Account_Condition) ExpectedDatabase(com.github.springtestdbunit.annotation.ExpectedDatabase) Test(org.junit.Test) SpringBootTest(org.springframework.boot.test.context.SpringBootTest) DatabaseSetup(com.github.springtestdbunit.annotation.DatabaseSetup) DatabaseTearDown(com.github.springtestdbunit.annotation.DatabaseTearDown)

Example 50 with Account_Condition

use of indi.mybatis.flying.pojo.condition.Account_Condition in project mybatis.flying by limeng32.

the class BatchProcessTest method testBatchUpdate3.

@Test
@DatabaseSetup(type = DatabaseOperation.CLEAN_INSERT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate3.xml")
@ExpectedDatabase(assertionMode = DatabaseAssertionMode.NON_STRICT, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate3.result.xml")
@DatabaseTearDown(type = DatabaseOperation.DELETE_ALL, value = "/indi/mybatis/flying/test/batchProcessTest/testBatchUpdate3.xml")
public void testBatchUpdate3() {
    Account_Condition ac = new Account_Condition();
    ac.setEmail("ann@tom.com");
    ac.setNameLessThan("c");
    accountService.update(ac);
}
Also used : Account_Condition(indi.mybatis.flying.pojo.condition.Account_Condition) ExpectedDatabase(com.github.springtestdbunit.annotation.ExpectedDatabase) Test(org.junit.Test) SpringBootTest(org.springframework.boot.test.context.SpringBootTest) DatabaseSetup(com.github.springtestdbunit.annotation.DatabaseSetup) DatabaseTearDown(com.github.springtestdbunit.annotation.DatabaseTearDown)

Aggregations

DatabaseTearDown (com.github.springtestdbunit.annotation.DatabaseTearDown)54 Account_Condition (indi.mybatis.flying.pojo.condition.Account_Condition)54 Test (org.junit.Test)50 DatabaseSetup (com.github.springtestdbunit.annotation.DatabaseSetup)46 SpringBootTest (org.springframework.boot.test.context.SpringBootTest)44 ExpectedDatabase (com.github.springtestdbunit.annotation.ExpectedDatabase)37 Account_ (indi.mybatis.flying.pojo.Account_)28 ArrayList (java.util.ArrayList)12 PageParam (indi.mybatis.flying.pagination.PageParam)11 IfProfileValue (org.springframework.test.annotation.IfProfileValue)10 Role_ (indi.mybatis.flying.pojo.Role_)9 LoginLog_ (indi.mybatis.flying.pojo.LoginLog_)6 LoginLog_Condition (indi.mybatis.flying.pojo.condition.LoginLog_Condition)6 Order (indi.mybatis.flying.pagination.Order)5 SortParam (indi.mybatis.flying.pagination.SortParam)5 Page (indi.mybatis.flying.pagination.Page)4 Role_Condition (indi.mybatis.flying.pojo.condition.Role_Condition)4 HashMap (java.util.HashMap)4 Permission (indi.mybatis.flying.pojo.Permission)1 Account_Condition3 (indi.mybatis.flying.pojo.condition.Account_Condition3)1