промежуточный. вариант с разбитием конфигурации сапфора и настройки как отдельный объект
This commit is contained in:
@@ -25,6 +25,8 @@ import TestingSystem.SAPFOR.Json.SapforPackage_json;
|
||||
import TestingSystem.SAPFOR.SapforConfiguration.SapforConfiguration;
|
||||
import TestingSystem.SAPFOR.SapforConfigurationCommand.SapforConfigurationCommand;
|
||||
import TestingSystem.SAPFOR.SapforPackage.SapforPackage;
|
||||
import TestingSystem.SAPFOR.SapforSettings.SapforSettings;
|
||||
import TestingSystem.SAPFOR.SapforSettingsCommand.SapforSettingsCommand;
|
||||
import TestingSystem.SAPFOR.SapforTestingPlanner;
|
||||
import TestingSystem.SAPFOR.ServerSapfor.ServerSapfor;
|
||||
import TestingSystem.SAPFOR.ServerSapfor.ServerSapforState;
|
||||
@@ -110,6 +112,16 @@ public class TestingServer extends RepositoryServer<TestsDatabase> {
|
||||
SapforPackage sapforPackage = (SapforPackage) object;
|
||||
File workspace = sapforPackage.getLocalWorkspace();
|
||||
Utils.forceDeleteWithCheck(workspace);
|
||||
} else if (object instanceof SapforSettings) {
|
||||
SapforSettings sapforSettings = (SapforSettings) object;
|
||||
Vector<SapforSettingsCommand> commands = new Vector<>();
|
||||
for (SapforSettingsCommand command : db.sapforSettingsCommands.Data.values()) {
|
||||
if (command.sapforsettings_id== sapforSettings.id)
|
||||
commands.add(command);
|
||||
}
|
||||
for (SapforSettingsCommand command : commands) {
|
||||
db.Delete(command);
|
||||
}
|
||||
}
|
||||
}
|
||||
//-->>>
|
||||
@@ -641,30 +653,6 @@ public class TestingServer extends RepositoryServer<TestsDatabase> {
|
||||
afterPublishAction(target);
|
||||
//--
|
||||
}
|
||||
/*
|
||||
public void PATCH() {
|
||||
for (DVMPackage testingPackage : db.dvmPackages.Data.values()) {
|
||||
boolean hasErrors = false;
|
||||
try {
|
||||
testingPackage.readJson();
|
||||
//---------------------------------------------------
|
||||
for (DVMCompilationTask compilationTask : testingPackage.package_json.compilationTasks) {
|
||||
if (!compilationTask.state.equals(TaskState.Done))
|
||||
hasErrors = true;
|
||||
for (DVMRunTask runTask : compilationTask.runTasks) {
|
||||
if (!runTask.state.equals(TaskState.Done))
|
||||
hasErrors = true;
|
||||
}
|
||||
}
|
||||
if (hasErrors)
|
||||
testingPackage.state = TasksPackageState.DoneWithErrors;
|
||||
//---------------------------------------------------
|
||||
db.Update(testingPackage);
|
||||
} catch (Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user