2 * Scaffolding file used to store all the setups needed to run
3 * tests automatically generated by EvoSuite
4 * Mon Nov 14 09:09:37 GMT 2016
7 package org.openecomp.mso.properties;
9 import org.evosuite.runtime.annotation.EvoSuiteClassExclude;
10 import org.junit.BeforeClass;
11 import org.junit.Before;
12 import org.junit.After;
13 import org.junit.AfterClass;
14 import org.evosuite.runtime.sandbox.Sandbox;
17 public class MsoPropertiesParametersESTestscaffolding {
20 public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule();
22 private static final java.util.Properties defaultProperties = (java.util.Properties) java.lang.System.getProperties().clone();
24 private org.evosuite.runtime.thread.ThreadStopper threadStopper = new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000);
27 public static void initEvoSuiteFramework() {
28 org.evosuite.runtime.RuntimeSettings.className = "org.openecomp.mso.properties.MsoPropertiesParameters";
29 org.evosuite.runtime.GuiSupport.initialize();
30 org.evosuite.runtime.RuntimeSettings.maxNumberOfThreads = 100;
31 org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000;
32 org.evosuite.runtime.RuntimeSettings.mockSystemIn = true;
33 org.evosuite.runtime.RuntimeSettings.sandboxMode = org.evosuite.runtime.sandbox.Sandbox.SandboxMode.RECOMMENDED;
34 org.evosuite.runtime.sandbox.Sandbox.initializeSecurityManagerForSUT();
35 org.evosuite.runtime.classhandling.JDKClassResetter.init();
37 org.evosuite.runtime.Runtime.getInstance().resetRuntime();
41 public static void clearEvoSuiteFramework(){
42 Sandbox.resetDefaultSecurityManager();
43 java.lang.System.setProperties((java.util.Properties) defaultProperties.clone());
47 public void initTestCase(){
48 threadStopper.storeCurrentThreads();
49 threadStopper.startRecordingTime();
50 org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().initHandler();
51 org.evosuite.runtime.sandbox.Sandbox.goingToExecuteSUTCode();
53 org.evosuite.runtime.GuiSupport.setHeadless();
54 org.evosuite.runtime.Runtime.getInstance().resetRuntime();
55 org.evosuite.runtime.agent.InstrumentingAgent.activate();
59 public void doneWithTestCase(){
60 threadStopper.killAndJoinClientThreads();
61 org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().safeExecuteAddedHooks();
62 org.evosuite.runtime.classhandling.JDKClassResetter.reset();
64 org.evosuite.runtime.sandbox.Sandbox.doneWithExecutingSUTCode();
65 org.evosuite.runtime.agent.InstrumentingAgent.deactivate();
66 org.evosuite.runtime.GuiSupport.restoreHeadlessMode();
70 private static void initializeClasses() {
71 org.evosuite.runtime.classhandling.ClassStateSupport.initializeClasses(MsoPropertiesParametersESTestscaffolding.class.getClassLoader() ,
72 "org.openecomp.mso.properties.MsoPropertiesParameters"
76 private static void resetClasses() {
77 org.evosuite.runtime.classhandling.ClassResetter.getInstance().setClassLoader(MsoPropertiesParametersESTestscaffolding.class.getClassLoader());
79 org.evosuite.runtime.classhandling.ClassStateSupport.resetClasses(
80 "org.openecomp.mso.logger.MsoLogger$Catalog",
81 "org.openecomp.mso.logger.MsoLogger",
82 "com.att.eelf.i18n.EELFResourceManager",
83 "com.att.eelf.i18n.EELFMsgs",
84 "com.att.eelf.i18n.EELFResourceManager$RESOURCE_TYPES",
85 "org.apache.xerces.jaxp.SAXParserFactoryImpl",
86 "org.apache.xerces.jaxp.SAXParserImpl",
87 "org.apache.xerces.parsers.XMLParser",
88 "org.apache.xerces.parsers.AbstractSAXParser",
89 "org.apache.xerces.parsers.SAXParser",
90 "org.apache.xerces.parsers.ObjectFactory",
91 "org.apache.xerces.util.ParserConfigurationSettings",
92 "org.apache.xerces.parsers.XML11Configuration",
93 "org.apache.xerces.parsers.XIncludeAwareParserConfiguration",
94 "org.apache.xerces.util.SymbolTable",
95 "org.apache.xerces.impl.XMLEntityManager",
96 "org.apache.xerces.util.AugmentationsImpl$SmallContainer",
97 "org.apache.xerces.impl.XMLEntityManager$ByteBufferPool",
98 "org.apache.xerces.impl.XMLEntityManager$CharacterBufferPool",
99 "org.apache.xerces.impl.XMLEntityScanner$1",
100 "org.apache.xerces.impl.XMLEntityScanner",
101 "org.apache.xerces.impl.XMLErrorReporter",
102 "org.apache.xerces.impl.XMLScanner",
103 "org.apache.xerces.impl.XMLDocumentFragmentScannerImpl",
104 "org.apache.xerces.impl.XMLDocumentScannerImpl",
105 "org.apache.xerces.util.XMLStringBuffer",
106 "org.apache.xerces.util.XMLAttributesImpl",
107 "org.apache.xerces.impl.XMLDTDScannerImpl",
108 "org.apache.xerces.impl.dtd.XMLDTDProcessor",
109 "org.apache.xerces.impl.dtd.XMLDTDValidator",
110 "org.apache.xerces.impl.validation.ValidationState",
111 "org.apache.xerces.impl.dtd.XMLElementDecl",
112 "org.apache.xerces.impl.dtd.XMLSimpleType",
113 "org.apache.xerces.impl.dv.DTDDVFactory",
114 "org.apache.xerces.impl.dv.ObjectFactory",
115 "org.apache.xerces.impl.dv.dtd.DTDDVFactoryImpl",
116 "org.apache.xerces.impl.XMLVersionDetector",
117 "org.apache.xerces.impl.msg.XMLMessageFormatter",
118 "org.apache.xerces.impl.io.UTF8Reader",
119 "org.apache.xerces.util.XMLSymbols",
120 "org.apache.xerces.xni.NamespaceContext",
121 "org.apache.xerces.util.XMLChar",
122 "org.apache.xerces.impl.Constants",
123 "com.att.eelf.configuration.EELFLogger$Level",
124 "com.att.eelf.configuration.EELFManager",
125 "org.openecomp.mso.logger.MessageEnum",
126 "org.openecomp.mso.properties.AbstractMsoProperties"