no message

This commit is contained in:
2023-11-08 23:13:16 +03:00
parent 4cd1a46c6d
commit f0a63d910f
6 changed files with 61 additions and 8 deletions

8
.idea/workspace.xml generated
View File

@@ -8,9 +8,11 @@
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment=""> <list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment="">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" /> <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/SapforTestingSystem/Json/SapforVersion_json.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/SapforTestingSystem/Json/SapforVersion_json.java" afterDir="false" /> <change beforePath="$PROJECT_DIR$/src/Common/Global.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/Common/Global.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/SapforTestingSystem/SapforTask/SapforTask.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/SapforTestingSystem/SapforTask/SapforTask.java" afterDir="false" /> <change beforePath="$PROJECT_DIR$/src/Common/UI/Menus_2023/MainMenuBar/MainMenuBar.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/Common/UI/Menus_2023/MainMenuBar/MainMenuBar.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/Visual_DVM_2021/UI/Main/SapforPackagesComparisonForm.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/Visual_DVM_2021/UI/Main/SapforPackagesComparisonForm.java" afterDir="false" /> <change beforePath="$PROJECT_DIR$/src/Repository/Server/ComponentsServer.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/Repository/Server/ComponentsServer.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/Repository/Server/ServerCode.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/Repository/Server/ServerCode.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/Visual_DVM_2021/Passes/All/TestPass.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/Visual_DVM_2021/Passes/All/TestPass.java" afterDir="false" />
</list> </list>
<option name="SHOW_DIALOG" value="false" /> <option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" /> <option name="HIGHLIGHT_CONFLICTS" value="true" />

View File

@@ -150,7 +150,7 @@ public class Global {
Log = new Loggable() { Log = new Loggable() {
@Override @Override
public String getLogHomePath() { public String getLogHomePath() {
return Paths.get(Home, "Components").toString(); return Paths.get(System.getProperty("user.dir"), "Components").toString();
} }
@Override @Override
public String getLogName() { public String getLogName() {

View File

@@ -58,12 +58,11 @@ public class MainMenuBar extends VisualiserMenuBar {
setIcon("/icons/Apply.png"); setIcon("/icons/Apply.png");
setToolTipText("Test"); setToolTipText("Test");
addActionListener(e -> { addActionListener(e -> {
SapforTestingPlanner planner =new SapforTestingPlanner(); Pass_2021.passes.get(PassCode_2021.TestPass).Do();
planner.Start();
}); });
} }
}); });
*/ */
//--- //---
ShowProject(false); ShowProject(false);

View File

@@ -75,6 +75,13 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
Account account = null; Account account = null;
if (!Global.properties.OldServer) { if (!Global.properties.OldServer) {
switch (code) { switch (code) {
case Patch:
Print("Очистка файлов в багрепортах");
for (BugReport bug: db.bugReports.Data.values()){
}
response = new ServerExchangeUnit_2021(ServerCode.OK);
break;
//<editor-fold desc="Регистрация"> //<editor-fold desc="Регистрация">
case CheckSubscriberRole: case CheckSubscriberRole:
Print("Проверить роль пользователя"); Print("Проверить роль пользователя");

View File

@@ -71,5 +71,7 @@ public enum ServerCode {
InstallSapforForTesting, InstallSapforForTesting,
StartSapforTests, StartSapforTests,
GetFirstActiveSapforTasksPackage, GetFirstActiveSapforTasksPackage,
DownloadSapforTasksPackage, OLD DownloadSapforTasksPackage,
Patch,
OLD
} }

View File

@@ -1,4 +1,47 @@
package Visual_DVM_2021.Passes.All; package Visual_DVM_2021.Passes.All;
import Common.Utils.Utils;
import Visual_DVM_2021.Passes.PassCode_2021;
import Visual_DVM_2021.Passes.Pass_2021; import Visual_DVM_2021.Passes.Pass_2021;
import java.io.File;
import java.nio.file.Paths;
public class TestPass extends Pass_2021 { public class TestPass extends Pass_2021 {
@Override
protected boolean needsAnimation() {
return super.needsAnimation();
}
@Override
protected void body() throws Exception {
File[] bugsFiles = Paths.get(System.getProperty("user.dir"), "Bugs").toFile().listFiles();
if (bugsFiles != null) {
for (File archive : bugsFiles) {
if (archive.isFile()) {
//----
File tmp = Utils.getTempFileName("archive");
//--
Pass_2021 unzip = passes.get(PassCode_2021.UnzipFolderPass);
unzip.Do(archive.getAbsolutePath(), tmp.getAbsolutePath(), false);
//--
File project = null;
//--
File[] files = tmp.listFiles();
if (files != null) {
for (File file : files) {
if (file.isDirectory())
project = file;
}
}
if (project != null) {
//--
Utils.deleteFilesByExtensions(project, "dep", "opt", "err", "proj");
//--
//на самом деле тут должен быть archive
Utils.forceDeleteWithCheck(archive);
Pass_2021 zip = passes.get(PassCode_2021.ZipFolderPass);
zip.Do(project.getAbsolutePath(), archive.getAbsolutePath());
}
}
}
}
}
} }