/**
 * Scaffolding file used to store all the setups needed to run 
 * tests automatically generated by EvoSuite
 * Wed Sep 19 22:12:36 GMT 2018
 */

package uk.ac.sanger.artemis.circular;

import org.evosuite.runtime.annotation.EvoSuiteClassExclude;
import org.junit.BeforeClass;
import org.junit.Before;
import org.junit.After;
import org.junit.AfterClass;
import org.evosuite.runtime.sandbox.Sandbox;
import org.evosuite.runtime.sandbox.Sandbox.SandboxMode;

import static org.evosuite.shaded.org.mockito.Mockito.*;
@EvoSuiteClassExclude
public class Ticks_ESTest_scaffolding {

  @org.junit.Rule 
  public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule();

  private static final java.util.Properties defaultProperties = (java.util.Properties) java.lang.System.getProperties().clone(); 

  private org.evosuite.runtime.thread.ThreadStopper threadStopper =  new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000);


  @BeforeClass 
  public static void initEvoSuiteFramework() { 
    org.evosuite.runtime.RuntimeSettings.className = "uk.ac.sanger.artemis.circular.Ticks"; 
    org.evosuite.runtime.GuiSupport.initialize(); 
    org.evosuite.runtime.RuntimeSettings.maxNumberOfThreads = 100; 
    org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000; 
    org.evosuite.runtime.RuntimeSettings.mockSystemIn = true; 
    org.evosuite.runtime.RuntimeSettings.sandboxMode = org.evosuite.runtime.sandbox.Sandbox.SandboxMode.RECOMMENDED; 
    org.evosuite.runtime.sandbox.Sandbox.initializeSecurityManagerForSUT(); 
    org.evosuite.runtime.classhandling.JDKClassResetter.init();
    setSystemProperties();
    initializeClasses();
    org.evosuite.runtime.Runtime.getInstance().resetRuntime(); 
    try { initMocksToAvoidTimeoutsInTheTests(); } catch(ClassNotFoundException e) {} 
  } 

  @AfterClass 
  public static void clearEvoSuiteFramework(){ 
    Sandbox.resetDefaultSecurityManager(); 
    java.lang.System.setProperties((java.util.Properties) defaultProperties.clone()); 
  } 

  @Before 
  public void initTestCase(){ 
    threadStopper.storeCurrentThreads();
    threadStopper.startRecordingTime();
    org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().initHandler(); 
    org.evosuite.runtime.sandbox.Sandbox.goingToExecuteSUTCode(); 
    setSystemProperties(); 
    org.evosuite.runtime.GuiSupport.setHeadless(); 
    org.evosuite.runtime.Runtime.getInstance().resetRuntime(); 
    org.evosuite.runtime.agent.InstrumentingAgent.activate(); 
  } 

  @After 
  public void doneWithTestCase(){ 
    threadStopper.killAndJoinClientThreads();
    org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().safeExecuteAddedHooks(); 
    org.evosuite.runtime.classhandling.JDKClassResetter.reset(); 
    resetClasses(); 
    org.evosuite.runtime.sandbox.Sandbox.doneWithExecutingSUTCode(); 
    org.evosuite.runtime.agent.InstrumentingAgent.deactivate(); 
    org.evosuite.runtime.GuiSupport.restoreHeadlessMode(); 
  } 

  public static void setSystemProperties() {
 
    java.lang.System.setProperties((java.util.Properties) defaultProperties.clone()); 
    java.lang.System.setProperty("file.encoding", "UTF-8"); 
    java.lang.System.setProperty("java.awt.headless", "true"); 
    java.lang.System.setProperty("java.io.tmpdir", "/var/folders/r3/l648tx8s7hn8ppds6z2bk5cc000h2n/T/"); 
    java.lang.System.setProperty("user.country", "GB"); 
    java.lang.System.setProperty("user.dir", "/Users/kp11/workspace/applications/Artemis-build-ci/Artemis"); 
    java.lang.System.setProperty("user.home", "/Users/kp11"); 
    java.lang.System.setProperty("user.language", "en"); 
    java.lang.System.setProperty("user.name", "kp11"); 
    java.lang.System.setProperty("user.timezone", ""); 
  }

  private static void initializeClasses() {
    org.evosuite.runtime.classhandling.ClassStateSupport.initializeClasses(Ticks_ESTest_scaffolding.class.getClassLoader() ,
      "uk.ac.sanger.artemis.circular.ScrollPanel",
      "uk.ac.sanger.artemis.circular.Graph",
      "uk.ac.sanger.artemis.circular.TextFieldInt",
      "uk.ac.sanger.artemis.ChangeListener",
      "uk.ac.sanger.artemis.EntryChangeListener",
      "uk.ac.sanger.artemis.circular.TrackManager",
      "uk.ac.sanger.artemis.circular.UserGraph",
      "uk.ac.sanger.artemis.circular.Block",
      "uk.ac.sanger.artemis.circular.TextFieldFloat",
      "uk.ac.sanger.artemis.circular.DNADraw",
      "uk.ac.sanger.artemis.circular.Feature",
      "uk.ac.sanger.artemis.FeatureChangeListener",
      "uk.ac.sanger.artemis.circular.Track",
      "uk.ac.sanger.artemis.io.RangeVector",
      "uk.ac.sanger.artemis.sequence.Bases",
      "uk.ac.sanger.artemis.circular.TextFieldSink",
      "uk.ac.sanger.artemis.circular.TextFieldInt$WholeNumberDocument",
      "uk.ac.sanger.artemis.circular.Ticks",
      "uk.ac.sanger.artemis.EntryGroup"
    );
  } 
  private static void initMocksToAvoidTimeoutsInTheTests() throws ClassNotFoundException { 
    mock(Class.forName("uk.ac.sanger.artemis.circular.DNADraw", false, Ticks_ESTest_scaffolding.class.getClassLoader()));
  }

  private static void resetClasses() {
    org.evosuite.runtime.classhandling.ClassResetter.getInstance().setClassLoader(Ticks_ESTest_scaffolding.class.getClassLoader()); 

    org.evosuite.runtime.classhandling.ClassStateSupport.resetClasses(
      "uk.ac.sanger.artemis.circular.Ticks",
      "uk.ac.sanger.artemis.circular.Ticks$1",
      "uk.ac.sanger.artemis.circular.Ticks$2",
      "uk.ac.sanger.artemis.circular.ScrollPanel",
      "uk.ac.sanger.artemis.circular.DNADraw",
      "uk.ac.sanger.artemis.circular.TextFieldSink",
      "uk.ac.sanger.artemis.circular.TextFieldInt",
      "uk.ac.sanger.artemis.circular.TextFieldInt$WholeNumberDocument",
      "uk.ac.sanger.artemis.circular.Graph",
      "uk.ac.sanger.artemis.circular.GCGraph",
      "uk.ac.sanger.artemis.circular.DNADraw$1",
      "uk.ac.sanger.artemis.util.StringVector",
      "uk.ac.sanger.artemis.circular.BlockComparator",
      "org.apache.xml.utils.DefaultErrorHandler",
      "org.apache.xml.utils.UnImplNode",
      "org.apache.xalan.templates.ElemTemplateElement",
      "org.apache.xalan.templates.Stylesheet",
      "org.apache.xalan.templates.StylesheetComposed",
      "org.apache.xalan.templates.StylesheetRoot",
      "org.apache.xpath.XPath",
      "org.apache.xpath.Expression",
      "org.apache.xpath.functions.Function",
      "org.apache.xpath.functions.FuncCurrent",
      "org.apache.xpath.functions.FuncLast",
      "org.apache.xpath.functions.FuncPosition",
      "org.apache.xpath.functions.FunctionOneArg",
      "org.apache.xpath.functions.FuncCount",
      "org.apache.xpath.functions.FuncId",
      "org.apache.xpath.functions.Function2Args",
      "org.apache.xalan.templates.FuncKey",
      "org.apache.xpath.functions.FunctionDef1Arg",
      "org.apache.xpath.functions.FuncLocalPart",
      "org.apache.xpath.functions.FuncNamespace",
      "org.apache.xpath.functions.FuncQname",
      "org.apache.xpath.functions.FuncGenerateId",
      "org.apache.xpath.functions.FuncNot",
      "org.apache.xpath.functions.FuncTrue",
      "org.apache.xpath.functions.FuncFalse",
      "org.apache.xpath.functions.FuncBoolean",
      "org.apache.xpath.functions.FuncLang",
      "org.apache.xpath.functions.FuncNumber",
      "org.apache.xpath.functions.FuncFloor",
      "org.apache.xpath.functions.FuncCeiling",
      "org.apache.xpath.functions.FuncRound",
      "org.apache.xpath.functions.FuncSum",
      "org.apache.xpath.functions.FuncString",
      "org.apache.xpath.functions.FuncStartsWith",
      "org.apache.xpath.functions.FuncContains",
      "org.apache.xpath.functions.FuncSubstringBefore",
      "org.apache.xpath.functions.FuncSubstringAfter",
      "org.apache.xpath.functions.FuncNormalizeSpace",
      "org.apache.xpath.functions.Function3Args",
      "org.apache.xpath.functions.FuncTranslate",
      "org.apache.xpath.functions.FunctionMultiArgs",
      "org.apache.xpath.functions.FuncConcat",
      "org.apache.xpath.functions.FuncSystemProperty",
      "org.apache.xpath.functions.FuncExtFunctionAvailable",
      "org.apache.xpath.functions.FuncExtElementAvailable",
      "org.apache.xpath.functions.FuncSubstring",
      "org.apache.xpath.functions.FuncStringLength",
      "org.apache.xpath.functions.FuncDoclocation",
      "org.apache.xpath.functions.FuncUnparsedEntityURI",
      "org.apache.xpath.compiler.FunctionTable",
      "org.apache.xpath.compiler.XPathParser",
      "org.apache.xpath.compiler.OpMap",
      "org.apache.xpath.compiler.Compiler",
      "org.apache.xml.utils.ObjectVector",
      "org.apache.xpath.compiler.Lexer",
      "org.apache.xpath.compiler.OpMapVector",
      "org.apache.xpath.compiler.Keywords",
      "org.apache.xpath.axes.WalkerFactory",
      "org.apache.xpath.objects.XObject",
      "org.apache.xpath.objects.XNumber",
      "org.apache.xpath.patterns.NodeTest",
      "org.apache.xpath.axes.PredicatedNodeTest",
      "org.apache.xpath.axes.LocPathIterator",
      "org.apache.xpath.axes.ChildIterator",
      "org.apache.xpath.axes.IteratorPool",
      "org.apache.xalan.templates.ElemTemplate",
      "org.apache.xpath.patterns.StepPattern",
      "org.apache.xalan.templates.ElemForEach",
      "org.apache.xalan.templates.ElemCallTemplate",
      "org.apache.xalan.templates.ElemApplyTemplates",
      "org.apache.xpath.patterns.UnionPattern",
      "org.apache.xalan.templates.ElemValueOf",
      "org.apache.xpath.axes.SelfIteratorNoPredicate",
      "org.apache.xalan.transformer.TransformerImpl",
      "org.apache.xml.utils.ObjectPool",
      "org.apache.xml.serializer.SerializerBase",
      "org.apache.xml.serializer.SecuritySupport",
      "org.apache.xml.serializer.SecuritySupport$4",
      "org.apache.xml.serializer.ToStream",
      "org.apache.xml.serializer.ToTextStream",
      "org.apache.xalan.templates.OutputProperties",
      "org.apache.xml.serializer.OutputPropertiesFactory",
      "org.apache.xml.serializer.OutputPropertiesFactory$1",
      "org.apache.xml.utils.ObjectStack",
      "org.apache.xml.utils.NodeVector",
      "org.apache.xalan.transformer.KeyManager",
      "org.apache.xml.utils.BoolStack",
      "org.apache.xalan.trace.TraceManager",
      "org.apache.xml.dtm.DTMManager",
      "org.apache.xpath.XPathContext",
      "org.apache.xml.utils.IntVector",
      "org.apache.xml.utils.IntStack",
      "org.apache.xml.utils.XMLStringFactory",
      "org.apache.xpath.objects.XMLStringFactoryImpl",
      "org.apache.xml.dtm.ObjectFactory",
      "org.apache.xml.dtm.SecuritySupport",
      "org.apache.xml.dtm.SecuritySupport$4",
      "org.apache.xml.dtm.SecuritySupport$7",
      "org.apache.xml.dtm.SecuritySupport$1",
      "org.apache.xml.dtm.SecuritySupport$2",
      "org.apache.xml.dtm.SecuritySupport$3",
      "org.apache.xml.dtm.SecuritySupport$6",
      "org.apache.xml.dtm.ref.DTMManagerDefault",
      "org.apache.xml.dtm.ref.ExtendedType",
      "org.apache.xml.dtm.ref.ExpandedNameTable",
      "org.apache.xml.dtm.ref.ExpandedNameTable$HashEntry",
      "org.apache.xpath.SourceTreeManager",
      "org.apache.xpath.XPathContext$XPathExpressionContext",
      "org.apache.xpath.VariableStack",
      "org.apache.xalan.transformer.StackGuard",
      "org.apache.xalan.transformer.CountersTable",
      "uk.ac.sanger.artemis.io.SimpleEntryInformation",
      "uk.ac.sanger.artemis.io.BlastEntryInformation",
      "uk.ac.sanger.artemis.io.Key",
      "org.apache.batik.bridge.ConcreteTextLayoutFactory",
      "org.apache.batik.bridge.BasicTextPainter",
      "org.apache.batik.gvt.text.GVTAttributedCharacterIterator$TextAttribute",
      "org.apache.batik.bridge.StrokingTextPainter",
      "org.apache.batik.bridge.SVGDocumentBridge",
      "org.apache.batik.bridge.UserAgentAdapter",
      "org.apache.batik.util.Service",
      "org.apache.batik.bridge.RhinoInterpreterFactory",
      "org.apache.batik.script.InterpreterPool",
      "org.apache.batik.bridge.BridgeContext",
      "org.apache.batik.bridge.DocumentLoader",
      "org.apache.batik.dom.util.SAXDocumentFactory",
      "org.apache.batik.anim.dom.SAXSVGDocumentFactory",
      "org.apache.batik.util.XMLResourceDescriptor",
      "org.apache.batik.dom.AbstractDOMImplementation",
      "org.apache.batik.dom.ExtensibleDOMImplementation",
      "org.apache.batik.dom.util.HashTable",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AElementFactory",
      "org.apache.batik.dom.util.HashTable$Entry",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AltGlyphElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AltGlyphDefElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AltGlyphItemElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AnimateElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AnimateColorElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AnimateMotionElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$AnimateTransformElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$CircleElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$ClipPathElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$ColorProfileElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$CursorElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$DefinitionSrcElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$DefsElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$DescElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$EllipseElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeBlendElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeColorMatrixElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeComponentTransferElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeCompositeElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeConvolveMatrixElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeDiffuseLightingElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeDisplacementMapElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeDistantLightElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeFloodElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeFuncAElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeFuncRElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeFuncGElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeFuncBElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeGaussianBlurElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeImageElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeMergeElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeMergeNodeElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeMorphologyElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeOffsetElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FePointLightElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeSpecularLightingElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeSpotLightElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeTileElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FeTurbulenceElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FilterElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FontElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FontFaceElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FontFaceFormatElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FontFaceNameElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FontFaceSrcElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$FontFaceUriElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$ForeignObjectElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$GElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$GlyphElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$GlyphRefElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$HkernElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$ImageElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$LineElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$LinearGradientElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$MarkerElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$MaskElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$MetadataElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$MissingGlyphElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$MpathElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$PathElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$PatternElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$PolygonElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$PolylineElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$RadialGradientElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$RectElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$SetElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$ScriptElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$StopElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$StyleElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$SvgElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$SwitchElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$SymbolElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$TextElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$TextPathElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$TitleElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$TrefElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$TspanElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$UseElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$ViewElementFactory",
      "org.apache.batik.anim.dom.SVGDOMImplementation$VkernElementFactory",
      "org.apache.batik.i18n.LocalizableSupport",
      "org.apache.batik.i18n.LocaleGroup",
      "org.apache.batik.anim.dom.SVGDOMImplementation",
      "org.apache.batik.util.Platform",
      "org.apache.batik.bridge.CursorManager",
      "org.apache.batik.util.SoftReferenceCache",
      "org.apache.batik.bridge.CursorManager$CursorCache",
      "org.apache.batik.bridge.UserAgentViewport",
      "org.apache.xmlgraphics.java2d.color.ICCColorSpaceWithIntent",
      "org.apache.batik.ext.awt.g2d.GraphicContext"
    );
  }
}
