Skip to content
This repository has been archived by the owner on Apr 21, 2024. It is now read-only.

Commit

Permalink
Add step to build repo without tests once before we start running int…
Browse files Browse the repository at this point in the history
…egration tests
  • Loading branch information
mefarazath committed May 11, 2019
1 parent 6e7b918 commit 7bb7eda
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion integration-tests/run-intg-test.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,16 @@ def configure_product():
logger.error("Error occurred while configuring the product", exc_info=True)


def build_source_without_tests(source_path):
"""Build the product-source.
"""
logger.info('Building the source skipping tests')
if sys.platform.startswith('win'):
subprocess.call(['mvn', 'clean', 'install', '-B', '-e','-Dmaven.test.skip=true'], shell=True, cwd=source_path)
else:
subprocess.call(['mvn', 'clean', 'install', '-B', '-e', '-Dmaven.test.skip=true'], cwd=source_path)
logger.info('Module build is completed. Module: ' + str(source_path))

def main():
try:
global logger
Expand Down Expand Up @@ -238,9 +248,10 @@ def main():

if cm.test_mode == "RELEASE":
cm.checkout_to_tag()

# product name retrieve from product pom files
dist_name = cm.get_dist_name(pom_path)
# build the product without test once to make samples and required artifacts to be available.
build_source_without_tests(cm.workspace + "/" + cm.product_id + "/")
cm.get_latest_released_dist()
elif cm.test_mode == "SNAPSHOT":
# product name retrieve from product pom files
Expand Down

0 comments on commit 7bb7eda

Please sign in to comment.