убрал возможность задавать тип машины как кластера

This commit is contained in:
2025-02-10 16:14:48 +03:00
parent bc750f8db0
commit 7eecdf8f4d
8 changed files with 41 additions and 15 deletions

View File

@@ -374,6 +374,9 @@ public class TestingServer extends RepositoryServer<TestsDatabase> {
Print("Получить максимальную установленную версию Sapfor");
GetSapforMaxVersion();
break;
case TestCode:
checkUnpackedTests();
break;
default:
throw new RepositoryRefuseException("Неподдерживаемый код: " + code);
}
@@ -742,5 +745,18 @@ public class TestingServer extends RepositoryServer<TestsDatabase> {
//--
return target;
}
public void checkUnpackedTests() throws Exception{
for (Test test: db.tests.Data.values()){
File testHome = test.getServerPath();
if (!testHome.exists()){
throw new RepositoryRefuseException(test.id+" не существует папка");
}
File testArchive = test.getArchive();
if (!testArchive.exists()){
throw new RepositoryRefuseException(test.id+" не существует архив");
}
}
response = new ServerExchangeUnit_2021(ServerCode.OK);
}
}