def general_func_test_runner(args, additional_options=None): if not additional_options: additional_options = {} maven = MavenCallable(args) maven.projects = ['jira-distribution/jira-func-tests-runner'] maven.option('-am') maven.profile('distribution') maven.phase('verify') maven.properties.update(additional_options) maven.property('system.bamboo.agent.home', os.path.abspath(os.sep.join(['jira-distribution', 'jira-func-tests-runner', 'target']))) return maven
def ual_int_func_test_runner(args): maven = MavenCallable(args) maven.projects = ['jira-distribution/jira-webapp-dist', 'jira-distribution/jira-integration-tests'] maven.option('-am') maven.profile('distribution') maven.phase('verify') maven.properties.update({'maven.test.unit.skip': 'true', 'jira.security.disabled': 'true', 'java.awt.headless': 'true', 'jira.minify.skip': 'true', 'func.mode.plugins': 'true'}) return maven
def webdriver_test_runner(args): maven = MavenCallable(args) maven.projects = ['jira-webdriver-tests'] maven.option('-am') maven.profile('jmake-webdriver-tests') maven.phase('test') maven.properties.update({'failIfNoTests': 'false', 'maven.test.unit.skip': 'true', 'system.bamboo.agent.home': os.path.abspath(os.sep.join(['jira-distribution', 'jira-webdriver-tests-runner', 'target'])) }) if args.tests is not None: maven.properties.update({'test': args.tests}) return maven
def general_func_test_runner(args, additional_options=None): if not additional_options: additional_options = {} maven = MavenCallable(args) maven.projects = ['jira-distribution/jira-func-tests-runner'] maven.option('-am') maven.profile('distribution') maven.phase('verify') maven.properties.update(additional_options) maven.property( 'system.bamboo.agent.home', os.path.abspath( os.sep.join( ['jira-distribution', 'jira-func-tests-runner', 'target']))) return maven
def __call__(self, args, executor): if self.fileutils.file_exists(dependencies_tmp): executor.append(lambda logger: self.fileutils.remove(dependencies_tmp) or 0) maven = MavenCallable(args, process_utils=self.process_utils) maven.projects = ['jira-components/jira-tests-parent/jira-tests', 'jira-components/jira-tests-parent/jira-tests-unit'] if not args.skip_legacy: maven.project('jira-components/jira-tests-parent/jira-tests-legacy') maven.option('-am') maven.phase('compile' if args.vdep else 'test') maven.property('verifyDependencies').property('jira.minify.skip', 'true').property('performApiCheck').property( 'ajEnforcer') maven.property('maven.test.func.skip', 'true').property('maven.test.selenium.skip', 'true') if not args.skip_bp: report_projects = ['jira-components/jira-tests-parent', 'jira-func-tests', 'jira-components/jira-plugins'] maven.project('jira-components/jira-plugins/jira-bundled-plugins') else: report_projects = ['jira-components/jira-tests-parent', 'jira-func-tests'] maven.project('jira-func-tests') try: maven.require_mvn3().can_run_in_parallel() except MavenVersionInaccessibleException: pass self.surefire.set_roots(report_projects) executor.append(self.surefire.clean_executable()) if args.findbugs: try: executor.append(maven.phase('test').profile('findbugs').require_mvn3()) except MavenVersionInaccessibleException as e: executor.append(maven.mvn3_inaccessible_msg_callable('unit tests with findbugs', e)) else: if args.vdep: executor.append(maven.phase('compile')) else: executor.append(maven.phase('test').option('--fail-at-end')) executor.append_post(self.surefire.report_executable()) executor.append_post(DependenciesReport(args))
def ual_int_func_test_runner(args): maven = MavenCallable(args) maven.projects = [ 'jira-distribution/jira-webapp-dist', 'jira-distribution/jira-integration-tests' ] maven.option('-am') maven.profile('distribution') maven.phase('verify') maven.properties.update({ 'maven.test.unit.skip': 'true', 'jira.security.disabled': 'true', 'java.awt.headless': 'true', 'jira.minify.skip': 'true', 'func.mode.plugins': 'true' }) return maven
def webdriver_test_runner(args): maven = MavenCallable(args) maven.projects = ['jira-webdriver-tests'] maven.option('-am') maven.profile('jmake-webdriver-tests') maven.phase('test') maven.properties.update({ 'failIfNoTests': 'false', 'maven.test.unit.skip': 'true', 'system.bamboo.agent.home': os.path.abspath( os.sep.join( ['jira-distribution', 'jira-webdriver-tests-runner', 'target'])) }) if args.tests is not None: maven.properties.update({'test': args.tests}) return maven