ScriptCollection 3.3.65__py3-none-any.whl → 3.3.67__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ScriptCollection/ScriptCollectionCore.py +2 -1
- ScriptCollection/TasksForCommonProjectStructure.py +11 -6
- {ScriptCollection-3.3.65.dist-info → ScriptCollection-3.3.67.dist-info}/METADATA +1 -1
- {ScriptCollection-3.3.65.dist-info → ScriptCollection-3.3.67.dist-info}/RECORD +7 -7
- {ScriptCollection-3.3.65.dist-info → ScriptCollection-3.3.67.dist-info}/WHEEL +0 -0
- {ScriptCollection-3.3.65.dist-info → ScriptCollection-3.3.67.dist-info}/entry_points.txt +0 -0
- {ScriptCollection-3.3.65.dist-info → ScriptCollection-3.3.67.dist-info}/top_level.txt +0 -0
|
@@ -27,7 +27,7 @@ from .ProgramRunnerPopen import ProgramRunnerPopen
|
|
|
27
27
|
from .ProgramRunnerEpew import ProgramRunnerEpew, CustomEpewArgument
|
|
28
28
|
|
|
29
29
|
|
|
30
|
-
version = "3.3.
|
|
30
|
+
version = "3.3.67"
|
|
31
31
|
__version__ = version
|
|
32
32
|
|
|
33
33
|
|
|
@@ -422,6 +422,7 @@ class ScriptCollectionCore:
|
|
|
422
422
|
@GeneralUtilities.check_arguments
|
|
423
423
|
def git_checkout(self, directory: str, branch: str) -> None:
|
|
424
424
|
self.run_program_argsasarray("git", ["checkout", branch], directory, throw_exception_if_exitcode_is_not_zero=True, verbosity=0)
|
|
425
|
+
self.run_program_argsasarray("git", ["submodule", "update", "--recursive"], directory, throw_exception_if_exitcode_is_not_zero=True, verbosity=0)
|
|
425
426
|
|
|
426
427
|
@GeneralUtilities.check_arguments
|
|
427
428
|
def git_merge_abort(self, directory: str) -> None:
|
|
@@ -101,6 +101,7 @@ class TasksForCommonProjectStructure:
|
|
|
101
101
|
__sc: ScriptCollectionCore = None
|
|
102
102
|
reference_latest_version_of_xsd_when_generating_xml: bool = True
|
|
103
103
|
validate_developers_of_repository: bool = True
|
|
104
|
+
dotnet_runsettings_file = "runsettings.xml"
|
|
104
105
|
|
|
105
106
|
@staticmethod
|
|
106
107
|
@GeneralUtilities.check_arguments
|
|
@@ -145,12 +146,13 @@ class TasksForCommonProjectStructure:
|
|
|
145
146
|
@GeneralUtilities.check_arguments
|
|
146
147
|
def check_testcoverage(self, testcoverage_file_in_cobertura_format: str, repository_folder: str, codeunitname: str):
|
|
147
148
|
root: etree._ElementTree = etree.parse(testcoverage_file_in_cobertura_format)
|
|
149
|
+
# TODO check if there is at least one package in testcoverage_file_in_cobertura_format
|
|
148
150
|
coverage_in_percent = round(float(str(root.xpath('//coverage/@line-rate')[0]))*100, 2)
|
|
149
151
|
codeunit_file = os.path.join(repository_folder, codeunitname, f"{codeunitname}.codeunit.xml")
|
|
150
152
|
threshold_in_percent = self.__get_testcoverage_threshold_from_codeunit_file(codeunit_file)
|
|
151
153
|
minimalrequiredtestcoverageinpercent = threshold_in_percent
|
|
152
154
|
if (coverage_in_percent < minimalrequiredtestcoverageinpercent):
|
|
153
|
-
raise ValueError(f"The testcoverage must be {minimalrequiredtestcoverageinpercent}% or more but is {coverage_in_percent}%.")
|
|
155
|
+
raise ValueError(f"The testcoverage for codeunit {codeunitname} must be {minimalrequiredtestcoverageinpercent}% or more but is {coverage_in_percent}%.")
|
|
154
156
|
|
|
155
157
|
@GeneralUtilities.check_arguments
|
|
156
158
|
def replace_version_in_python_file(self, file: str, new_version_value: str):
|
|
@@ -566,11 +568,11 @@ class TasksForCommonProjectStructure:
|
|
|
566
568
|
coverage_file_folder = os.path.join(repository_folder, codeunit_name, "Other/Artifacts/TestCoverage")
|
|
567
569
|
working_directory = os.path.join(repository_folder, codeunit_name)
|
|
568
570
|
runsettings_argument = ""
|
|
569
|
-
runsettings_file =
|
|
571
|
+
runsettings_file = self.dotnet_runsettings_file
|
|
570
572
|
if os.path.isfile(os.path.join(working_directory, runsettings_file)):
|
|
571
573
|
runsettings_argument = f"--settings {runsettings_file} "
|
|
572
|
-
|
|
573
|
-
|
|
574
|
+
arg = f"collect dotnet test {runsettings_argument}-c {dotnet_build_configuration} --output-format cobertura --output Other\\Artifacts\\TestCoverage\\Testcoverage"
|
|
575
|
+
self.__sc.run_program("dotnet-coverage", arg, working_directory, verbosity=verbosity)
|
|
574
576
|
os.rename(os.path.join(coverage_file_folder, "Testcoverage.cobertura.xml"), os.path.join(coverage_file_folder, "TestCoverage.xml"))
|
|
575
577
|
self.run_testcases_common_post_task(repository_folder, codeunit_name, verbosity, generate_badges, targetenvironmenttype, commandline_arguments)
|
|
576
578
|
|
|
@@ -1006,7 +1008,10 @@ class TasksForCommonProjectStructure:
|
|
|
1006
1008
|
for actual_author in actual_authors:
|
|
1007
1009
|
if not (actual_author) in expected_authors:
|
|
1008
1010
|
actual_author_formatted = f"{actual_author[0]} <{actual_author[1]}>"
|
|
1009
|
-
raise ValueError(f'Author/Comitter "{actual_author_formatted}" is not in the codeunit-developer-team.'
|
|
1011
|
+
raise ValueError(f'Author/Comitter "{actual_author_formatted}" is not in the codeunit-developer-team. If {actual_author} is a '
|
|
1012
|
+
+ 'authorized developer for this codeunit you should consider defining this in the codeunit-file or adapting the name using a '
|
|
1013
|
+
+ '.mailmap-file (see https://git-scm.com/docs/gitmailmap). The developer-team-check can also be disabled using '
|
|
1014
|
+
+ 'the property validate_developers_of_repository.')
|
|
1010
1015
|
|
|
1011
1016
|
# TODO implement cycle-check for dependent codeunits
|
|
1012
1017
|
|
|
@@ -1246,7 +1251,7 @@ class TasksForCommonProjectStructure:
|
|
|
1246
1251
|
example_name = os.path.basename(folder)
|
|
1247
1252
|
GeneralUtilities.write_message_to_stdout(f'Run "{example_name}"-example')
|
|
1248
1253
|
sc = ScriptCollectionCore()
|
|
1249
|
-
oci_image_artifacts_folder = GeneralUtilities.resolve_relative_path("
|
|
1254
|
+
oci_image_artifacts_folder = GeneralUtilities.resolve_relative_path("../../../../Artifacts/BuildResult_OCIImage", folder)
|
|
1250
1255
|
image_filename = os.path.basename(sc.find_file_by_extension(oci_image_artifacts_folder, "tar"))
|
|
1251
1256
|
codeunit_name = os.path.basename(GeneralUtilities.resolve_relative_path("../../..", folder))
|
|
1252
1257
|
codeunit_name_lower = codeunit_name.lower()
|
|
@@ -3,12 +3,12 @@ ScriptCollection/GeneralUtilities.py,sha256=Blo0Iq-G4zuUL5oUxBTeGFtQ23ndK7dpZPOj
|
|
|
3
3
|
ScriptCollection/ProgramRunnerBase.py,sha256=2kyOuoM3oFjBfLc9Q5t5RTz7Ya2CjUxFtB1rBBDmnjU,1937
|
|
4
4
|
ScriptCollection/ProgramRunnerEpew.py,sha256=ZiBZVMcsphmo49z2BwUwQYXo2uTKXPu33QW3IxCT46E,6273
|
|
5
5
|
ScriptCollection/ProgramRunnerPopen.py,sha256=HOs1QVnXiQtwXy1_xvH79bWBdd0i-2tUyyLloQBvMto,3023
|
|
6
|
-
ScriptCollection/ScriptCollectionCore.py,sha256=
|
|
7
|
-
ScriptCollection/TasksForCommonProjectStructure.py,sha256=
|
|
6
|
+
ScriptCollection/ScriptCollectionCore.py,sha256=AaqVkBaeQIZi6wSoAsY-vLwYaPT045ASo740q53z_e4,86136
|
|
7
|
+
ScriptCollection/TasksForCommonProjectStructure.py,sha256=JUqkBOqA3DlZqCOOODPmprlmHJSRBHzYCQENsBWb10U,106445
|
|
8
8
|
ScriptCollection/UpdateCertificates.py,sha256=Go-JJK-YTi7aBB1phlLxypa8GHkmFHBEPB0_TT9G-bw,7918
|
|
9
9
|
ScriptCollection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
-
ScriptCollection-3.3.
|
|
11
|
-
ScriptCollection-3.3.
|
|
12
|
-
ScriptCollection-3.3.
|
|
13
|
-
ScriptCollection-3.3.
|
|
14
|
-
ScriptCollection-3.3.
|
|
10
|
+
ScriptCollection-3.3.67.dist-info/METADATA,sha256=V3bnAt7raah9G_QBMI1a5eYg4LOsrHcI-IdP-P7Xr4A,7878
|
|
11
|
+
ScriptCollection-3.3.67.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
|
12
|
+
ScriptCollection-3.3.67.dist-info/entry_points.txt,sha256=VIuxVCOpX38lSJUwRRENBNgcGKTIBxQyrCfbJVRHP8g,1968
|
|
13
|
+
ScriptCollection-3.3.67.dist-info/top_level.txt,sha256=hY2hOVH0V0Ce51WB76zKkIWTUNwMUdHo4XDkR2vYVwg,17
|
|
14
|
+
ScriptCollection-3.3.67.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|