diff options
Diffstat (limited to 'scripts/BuildArchetypes.py')
-rw-r--r-- | scripts/BuildArchetypes.py | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/scripts/BuildArchetypes.py b/scripts/BuildArchetypes.py index fa6dba2c56..98fe787d77 100644 --- a/scripts/BuildArchetypes.py +++ b/scripts/BuildArchetypes.py @@ -73,6 +73,8 @@ if __name__ == "__main__": if hasattr(args, "artifactPath") and args.artifactPath is not None: raise Exception("Archetype validation build does not support artifactPath") + wars = {} + for archetype in archetypes: artifactId = "test-%s-%s" % (archetype, args.version.replace(".", "-")) try: @@ -82,15 +84,23 @@ if __name__ == "__main__": mavenValidate(artifactId, logFile=log) warFiles = copyWarFiles(artifactId, name=archetype) for war in warFiles: - try: - deployWar(war, "%s.war" % (getDeploymentContext(archetype, args.version))) - except Exception as e: - print("War %s failed to deploy: %s" % (war, e)) - archetypesFailed = True + wars[war] = "%s.war" % (getDeploymentContext(archetype, args.version)) + print("%s validation succeeded!" % (archetype)) except Exception as e: print("Archetype %s build failed:" % (archetype), e) archetypesFailed = True -# removeDir(artifactId) + try: + removeDir(artifactId) + except: + pass print("") + + for i in wars: + try: + deployWar(i, wars[i]) + except Exception as e: + print("War %s failed to deploy: %s" % (war, e)) + archetypesFailed = True + if archetypesFailed: sys.exit(1) |