Class EmbeddedSutController
java.lang.Object
org.evomaster.client.java.controller.internal.SutController
org.evomaster.client.java.controller.EmbeddedSutController
- All Implemented Interfaces:
CustomizationHandler,SutHandler
Main class used to implement an EvoMaster Driver. A user that wants to use EvoMaster for white-box testing will need to implement this abstract class.
For full details on how to implement this class, look at the documentation for Write an EvoMaster Driver for White-Box Testing, currently at https://github.com/WebFuzzing/EvoMaster/blob/master/docs/write_driver.md
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal voidbootingSut(boolean bootingSut) specify whether the SUT is booting (ie starting up), or not.final List<AdditionalInfo>final Stringfinal voidgetJvmDtoSchema(List<String> dtoNames) final List<TargetInfo>getTargetInfos(Collection<Integer> ids, boolean fullyCovered, boolean descriptiveIds) final UnitsInfoDtofinal booleanCheck if bytecode instrumentation is on.final voidfinal voidfinal voidRe-initialize all internal data to enable a completely new search phase which should be independent from previous onesfinal voidfinal voidsetExecutingAction(boolean executingAction) final voidsetExecutingInitMongo(boolean executingInitMongo) final voidsetExecutingInitSql(boolean executingInitSql) final voidsetKillSwitch(boolean b) final voidThere might be different settings based on when the SUT is run during the search of EvoMaster, and when it is later started in the generated tests.Methods inherited from class org.evomaster.client.java.controller.internal.SutController
addSuccessfulInitSqlInsertion, addTableToInserted, categorizeBasedOnResponse, cleanAccessedTables, computeExtraHeuristics, computeMongoHeuristics, computeOpenSearchHeuristics, customizeMockingDatabase, customizeMockingRPCExternalService, customizeRPCTestOutput, customizeScheduleTaskInvocation, deriveObjectParameterData, doEmploySmartDbClean, enableComputeSqlHeuristicsOrExtractExecution, execInsertionsIntoDatabase, execInsertionsIntoMongoDatabase, executeAction, executeHandleLocalAuthenticationSetup, executeRPCEndpoint, extractRPCProblemDto, extractRPCSchema, extractSqlDbSchemaAndConstraints, getActionIndex, getBootTimeInfoDto, getConnection, getConnectionIfExist, getControllerHost, getControllerPort, getControllerServerPort, getCustomizedValueInRequests, getDatabaseDriverName, getExceptionImportanceLevels, getExtraHeuristics, getInfoForAuthentication, getLocalAuthSetupSchemaMap, getPackagePrefixesToCover, getPreferredOutputFormat, getProblemInfo, getRPCClient, getRPCSchema, getSqlDatabaseSchema, getUnitsInfoDto, handleSeededTests, initMongoHandler, initOpenSearchHandler, initSqlHandler, invokeScheduleTasks, invokeScheduleTaskWithCustomizedHandling, isScheduleTaskCompleted, isSutRunning, mockDatabasesWithCustomizedHandling, mockRPCExternalServicesWithCustomizedHandling, newAction, newScheduleAction, newTest, packagesToSkipInstrumentation, postSearchAction, readFileAsStringFromTestResource, registerOrExecuteInitSqlCommandsIfNeeded, registerOrExecuteInitSqlCommandsIfNeeded, resetCustomizedMethodForMockObject, resetDatabase, resetExtraHeuristics, seedRPCTests, setControllerHost, setControllerPort, specifyCustomizedNotNullAnnotation, startTheControllerServer, stopTheControllerServer, verifySqlConnectionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.evomaster.client.java.controller.SutHandler
getDbSpecifications, getMongoConnection, getOpenSearchConnection, getRedisConnection, handleLocalAuthenticationSetup, resetStateOfSUT, startSut, stopSut
-
Constructor Details
-
EmbeddedSutController
public EmbeddedSutController()
-
-
Method Details
-
setupForGeneratedTest
public final void setupForGeneratedTest()Description copied from interface:SutHandlerThere might be different settings based on when the SUT is run during the search of EvoMaster, and when it is later started in the generated tests. -
isInstrumentationActivated
public final boolean isInstrumentationActivated()Description copied from class:SutControllerCheck if bytecode instrumentation is on.- Specified by:
isInstrumentationActivatedin classSutController- Returns:
- true if the instrumentation is on
-
newSearch
public final void newSearch()Description copied from class:SutControllerRe-initialize all internal data to enable a completely new search phase which should be independent from previous ones- Specified by:
newSearchin classSutController
-
newTestSpecificHandler
public final void newTestSpecificHandler()- Specified by:
newTestSpecificHandlerin classSutController
-
getTargetInfos
public final List<TargetInfo> getTargetInfos(Collection<Integer> ids, boolean fullyCovered, boolean descriptiveIds) - Specified by:
getTargetInfosin classSutController
-
getAdditionalInfoList
- Specified by:
getAdditionalInfoListin classSutController- Returns:
- additional info for each action in the test. The list is ordered based on the action index.
-
newActionSpecificHandler
- Specified by:
newActionSpecificHandlerin classSutController
-
newScheduleActionSpecificHandler
- Specified by:
newScheduleActionSpecificHandlerin classSutController
-
getUnitsInfoDto
- Specified by:
getUnitsInfoDtoin classSutController
-
setKillSwitch
public final void setKillSwitch(boolean b) - Specified by:
setKillSwitchin classSutController
-
setExecutingInitSql
public final void setExecutingInitSql(boolean executingInitSql) - Specified by:
setExecutingInitSqlin classSutController
-
setExecutingInitMongo
public final void setExecutingInitMongo(boolean executingInitMongo) - Specified by:
setExecutingInitMongoin classSutController
-
setExecutingAction
public final void setExecutingAction(boolean executingAction) - Specified by:
setExecutingActionin classSutController
-
getBootTimeInfoDto
- Specified by:
getBootTimeInfoDtoin classSutController
-
getExecutableFullPath
- Specified by:
getExecutableFullPathin classSutController
-
getJvmDtoSchema
- Specified by:
getJvmDtoSchemain classSutController
-
bootingSut
public final void bootingSut(boolean bootingSut) Description copied from class:SutControllerspecify whether the SUT is booting (ie starting up), or not. this is needed because we don't want to handle targets covered at startup during the fitness evaluations- Specified by:
bootingSutin classSutController
-