forked from RihanKh/OSAandSAST
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathUsersTest.java
69 lines (69 loc) · 2.62 KB
/
UsersTest.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
//package com.cx.automation.dbtest;
//
//import com.cx.automation.adk.systemtest.runner.E2ETest;
//import com.cx.automation.adk.systemtest.runner.E2ETestSpringRunner;
//import com.cx.automation.persistence.appdatabase.configuration.ConfigurationDAOService;
//import com.cx.automation.persistence.appdatabase.configuration.dto.EngineConfigurationKeysMeta;
//import org.junit.Before;
//import org.junit.Test;
//import org.junit.runner.RunWith;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.test.annotation.IfProfileValue;
//import org.springframework.test.context.ContextConfiguration;
//import org.springframework.test.context.transaction.TransactionConfiguration;
//import org.springframework.transaction.annotation.Transactional;
//
//import static com.cx.automation.topology.EnvironmentConstants.ENVIRONMENT;
//import static com.cx.automation.topology.EnvironmentConstants.EXTERNAL_ENV;
//
///**
// * Created by Dima Masis
// * Date 18/10/2016
// */
//
//@RunWith(E2ETestSpringRunner.class)
//@ContextConfiguration(locations = {"classpath:com/cx/automation/persistence/cx-persistence-context.xml"})
//@TransactionConfiguration(defaultRollback = false)
//public class UsersTest {
//
// @Autowired
// private ConfigurationDAOService configurationDAOService;
//
//
// @Transactional
// @Before
// public void doBeforeTest() {
//
//
// EngineConfigurationKeysMeta before_update = configurationDAOService.getEngineConfigurationValueByKey("MULTI_LANGUAGE_MODE");
// System.err.println("BEFORE UPDATE: " + before_update.getDefaultValue() + " key: " + before_update.getKeyName());
//
// String changedVal;
// if (before_update.getDefaultValue().equals("1")) {
// changedVal = "2";
// } else {
// changedVal = "1";
// }
// configurationDAOService.updateEngineConfigurationKeysMeta("MULTI_LANGUAGE_MODE", changedVal);
//
// EngineConfigurationKeysMeta after_update = configurationDAOService.getEngineConfigurationValueByKey("MULTI_LANGUAGE_MODE");
// System.err.println("AFTER UPDATE: " + after_update.getDefaultValue() + " key: " + after_update.getKeyName());
//
// }
//
// @Test
// @E2ETest
// @IfProfileValue(name = ENVIRONMENT, values = {EXTERNAL_ENV})
// public void usersDAOTest() {
// System.out.println("Test 1");
//
// }
//
// @Test
// @E2ETest(dependsOn = "usersDAOTest")
// @IfProfileValue(name = ENVIRONMENT, values = {EXTERNAL_ENV})
// public void usersDAOTest_2() {
// System.out.println("Test 2");
// }
//
//}