From 5193567a8118751664aec80a2d6ca78606cf61d3 Mon Sep 17 00:00:00 2001 From: bunsenstraat Date: Sun, 21 Nov 2021 13:24:19 +0100 Subject: [PATCH] group script --- .circleci/config.yml | 6 +++-- ...t_0_4_11.spec.ts => ballot_0_4_11.test.ts} | 0 .../{debugger.spec.ts => debugger.test.ts} | 0 ...er_api.spec.ts => fileManager_api.test.ts} | 0 .../src/tests/{gist.spec.ts => gist.test.ts} | 0 .../{recorder.spec.ts => recorder.test.ts} | 0 ...yImport.spec.ts => solidityImport.test.ts} | 0 ...ests.spec.ts => solidityUnittests.test.ts} | 0 ...nalysis.spec.ts => staticAnalysis.test.ts} | 0 apps/remix-ide-e2e/src/tests/terminal.test.ts | 2 +- ...n.spec.ts => transactionExecution.test.ts} | 0 ...nel.spec.ts => verticalIconsPanel.test.ts} | 0 ...wser_tests_chrome_1.sh => browser_test.sh} | 2 +- ..._firefox_1.sh => browser_tests_firefox.sh} | 0 package.json | 27 +++++++++---------- 15 files changed, 19 insertions(+), 18 deletions(-) rename apps/remix-ide-e2e/src/tests/{ballot_0_4_11.spec.ts => ballot_0_4_11.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{debugger.spec.ts => debugger.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{fileManager_api.spec.ts => fileManager_api.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{gist.spec.ts => gist.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{recorder.spec.ts => recorder.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{solidityImport.spec.ts => solidityImport.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{solidityUnittests.spec.ts => solidityUnittests.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{staticAnalysis.spec.ts => staticAnalysis.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{transactionExecution.spec.ts => transactionExecution.test.ts} (100%) rename apps/remix-ide-e2e/src/tests/{verticalIconsPanel.spec.ts => verticalIconsPanel.test.ts} (100%) rename apps/remix-ide/ci/{browser_tests_chrome_1.sh => browser_test.sh} (92%) rename apps/remix-ide/ci/{browser_tests_firefox_1.sh => browser_tests_firefox.sh} (100%) diff --git a/.circleci/config.yml b/.circleci/config.yml index 5a5fbfd54a..defa0512a3 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -121,7 +121,8 @@ jobs: name: Start Selenium command: npx selenium-standalone start background: true - - run: ./apps/remix-ide/ci/browser_tests_chrome_1.sh + - run: export BROWSER="chrome" + - run: ./apps/remix-ide/ci/browser_test.sh - store_test_results: path: ./reports/tests - store_artifacts: @@ -158,7 +159,8 @@ jobs: name: Start Selenium command: npx selenium-standalone start background: true - - run: ./apps/remix-ide/ci/browser_tests_firefox_1.sh + - run: export BROWSER="firefox" + - run: ./apps/remix-ide/ci/browser_test.sh - store_test_results: path: ./reports/tests - store_artifacts: diff --git a/apps/remix-ide-e2e/src/tests/ballot_0_4_11.spec.ts b/apps/remix-ide-e2e/src/tests/ballot_0_4_11.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/ballot_0_4_11.spec.ts rename to apps/remix-ide-e2e/src/tests/ballot_0_4_11.test.ts diff --git a/apps/remix-ide-e2e/src/tests/debugger.spec.ts b/apps/remix-ide-e2e/src/tests/debugger.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/debugger.spec.ts rename to apps/remix-ide-e2e/src/tests/debugger.test.ts diff --git a/apps/remix-ide-e2e/src/tests/fileManager_api.spec.ts b/apps/remix-ide-e2e/src/tests/fileManager_api.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/fileManager_api.spec.ts rename to apps/remix-ide-e2e/src/tests/fileManager_api.test.ts diff --git a/apps/remix-ide-e2e/src/tests/gist.spec.ts b/apps/remix-ide-e2e/src/tests/gist.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/gist.spec.ts rename to apps/remix-ide-e2e/src/tests/gist.test.ts diff --git a/apps/remix-ide-e2e/src/tests/recorder.spec.ts b/apps/remix-ide-e2e/src/tests/recorder.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/recorder.spec.ts rename to apps/remix-ide-e2e/src/tests/recorder.test.ts diff --git a/apps/remix-ide-e2e/src/tests/solidityImport.spec.ts b/apps/remix-ide-e2e/src/tests/solidityImport.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/solidityImport.spec.ts rename to apps/remix-ide-e2e/src/tests/solidityImport.test.ts diff --git a/apps/remix-ide-e2e/src/tests/solidityUnittests.spec.ts b/apps/remix-ide-e2e/src/tests/solidityUnittests.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/solidityUnittests.spec.ts rename to apps/remix-ide-e2e/src/tests/solidityUnittests.test.ts diff --git a/apps/remix-ide-e2e/src/tests/staticAnalysis.spec.ts b/apps/remix-ide-e2e/src/tests/staticAnalysis.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/staticAnalysis.spec.ts rename to apps/remix-ide-e2e/src/tests/staticAnalysis.test.ts diff --git a/apps/remix-ide-e2e/src/tests/terminal.test.ts b/apps/remix-ide-e2e/src/tests/terminal.test.ts index dafb3709af..0bcfbcb3d7 100644 --- a/apps/remix-ide-e2e/src/tests/terminal.test.ts +++ b/apps/remix-ide-e2e/src/tests/terminal.test.ts @@ -8,7 +8,7 @@ module.exports = { init(browser, done, 'http://127.0.0.1:8080?plugins=solidity,udapp', false) }, - 'Should execution a simple console command #group1': function (browser: NightwatchBrowser) { + 'Should execution a simple console command #group1 #group999': function (browser: NightwatchBrowser) { browser .waitForElementVisible('*[data-id="terminalCli"]', 10000) .executeScript('console.log(1 + 1)') diff --git a/apps/remix-ide-e2e/src/tests/transactionExecution.spec.ts b/apps/remix-ide-e2e/src/tests/transactionExecution.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/transactionExecution.spec.ts rename to apps/remix-ide-e2e/src/tests/transactionExecution.test.ts diff --git a/apps/remix-ide-e2e/src/tests/verticalIconsPanel.spec.ts b/apps/remix-ide-e2e/src/tests/verticalIconsPanel.test.ts similarity index 100% rename from apps/remix-ide-e2e/src/tests/verticalIconsPanel.spec.ts rename to apps/remix-ide-e2e/src/tests/verticalIconsPanel.test.ts diff --git a/apps/remix-ide/ci/browser_tests_chrome_1.sh b/apps/remix-ide/ci/browser_test.sh similarity index 92% rename from apps/remix-ide/ci/browser_tests_chrome_1.sh rename to apps/remix-ide/ci/browser_test.sh index bc9cb423c6..853c602bd8 100755 --- a/apps/remix-ide/ci/browser_tests_chrome_1.sh +++ b/apps/remix-ide/ci/browser_test.sh @@ -17,7 +17,7 @@ npm run build:e2e TESTFILES=$(grep -IRiL "disabled" "dist/apps/remix-ide-e2e/src/tests" | grep "\.spec\|\.test" | sort | circleci tests split ) for TESTFILE in $TESTFILES; do - npx nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js $TESTFILE --env=chrome || TEST_EXITCODE=1 + npx nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js $TESTFILE --env=$BROWSER || TEST_EXITCODE=1 done echo "$TEST_EXITCODE" diff --git a/apps/remix-ide/ci/browser_tests_firefox_1.sh b/apps/remix-ide/ci/browser_tests_firefox.sh similarity index 100% rename from apps/remix-ide/ci/browser_tests_firefox_1.sh rename to apps/remix-ide/ci/browser_tests_firefox.sh diff --git a/package.json b/package.json index a2bde3e78e..889e97a03d 100644 --- a/package.json +++ b/package.json @@ -59,39 +59,38 @@ "minify": "uglifyjs --in-source-map inline --source-map-inline -c warnings=false", "build:production": "NODE_ENV=production nx build remix-ide --skip-nx-cache", "serve:production": "npx http-server ./dist/apps/remix-ide", + "group_test":"npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/${npm_config_test}_group${npm_config_group}.test.js --env=${npm_config_env}", "nightwatch_parallel": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js --env=chrome,firefox", "nightwatch_local_firefox": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js --env=firefox", "nightwatch_local_chrome": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js --env=chrome", - "debugger_group_2": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/debugger_group_2.spec.js --env=chrome", - "debugger_group_1": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/debugger_group_1.spec.js --env=chrome", "nightwatch_local_ballot": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/ballot.test.js --env=chrome", - "nightwatch_local_ballot_0_4_11": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/ballot_0_4_11.spec.js --env=chrome", + "nightwatch_local_ballot_0_4_11": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/ballot_0_4_11.test.js --env=chrome", "nightwatch_local_usingWorker": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/usingWebWorker.test.js --env=chrome", "nightwatch_local_libraryDeployment": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/libraryDeployment.test.js --env=chrome", - "nightwatch_local_solidityImport": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/solidityImport_*.spec.js --env=chrome", - "nightwatch_local_recorder": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/recorder.spec.js --env=chrome", - "nightwatch_local_transactionExecution": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/transactionExecution_*.spec.js --env=chrome", - "nightwatch_local_staticAnalysis": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/staticAnalysis.spec.js --env=chrome", + "nightwatch_local_solidityImport": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/solidityImport_*.test.js --env=chrome", + "nightwatch_local_recorder": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/recorder.test.js --env=chrome", + "nightwatch_local_transactionExecution": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/transactionExecution_*.test.js --env=chrome", + "nightwatch_local_staticAnalysis": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/staticAnalysis.test.js --env=chrome", "nightwatch_local_signingMessage": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/signingMessage.test.js --env=chrome", "nightwatch_local_specialFunctions": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/specialFunctions_*.test.js --env=chrome", - "nightwatch_local_solidityUnitTests": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/solidityUnittests_*.spec.js --env=chrome", + "nightwatch_local_solidityUnitTests": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/solidityUnittests_*.test.js --env=chrome", "nightwatch_local_remixd": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/remixd.test.js --env=chrome", "nightwatch_local_terminal": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/terminal_*.test.js --env=chrome", - "nightwatch_local_gist": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/gist.spec.js --env=chrome", + "nightwatch_local_gist": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/gist.test.js --env=chrome", "nightwatch_local_workspace": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/workspace.test.js --env=chrome", "nightwatch_local_defaultLayout": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/defaultLayout.test.js --env=chrome", "nightwatch_local_pluginManager": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/pluginManager.test.js --env=chrome", "nightwatch_local_publishContract": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/publishContract.test.js --env=chrome", "nightwatch_local_generalSettings": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/generalSettings.test.js --env=chrome", "nightwatch_local_fileExplorer": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/fileExplorer.test.js --env=chrome", - "nightwatch_local_debugger": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/debugger_*.spec.js --env=chrome", - "nightwatch_local_editor": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/editor.spec.js --env=chrome", + "nightwatch_local_debugger": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/debugger_*.test.js --env=chrome", + "nightwatch_local_editor": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/editor.test.js --env=chrome", "nightwatch_local_compiler": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/compiler_api.test.js --env=chrome", "nightwatch_local_txListener": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/txListener.test.js --env=chrome", - "nightwatch_local_fileManager": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/fileManager_api.spec.js --env=chrome", + "nightwatch_local_fileManager": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/fileManager_api.test.js --env=chrome", "nightwatch_local_runAndDeploy": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/runAndDeploy.js --env=chrome-runAndDeploy", - "nightwatch_local_url": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/url.spec.js --env=chrome", - "nightwatch_local_verticalIconscontextmenu": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/verticalIconsPanel.spec.js --env=chrome", + "nightwatch_local_url": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/url.test.js --env=chrome", + "nightwatch_local_verticalIconscontextmenu": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/verticalIconsPanel.test.js --env=chrome", "nightwatch_local_pluginApi": "npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js dist/apps/remix-ide-e2e/src/tests/plugin_api_*.js --env=chrome", "onchange": "onchange apps/remix-ide/build/app.js -- npm-run-all lint", "remixd": "nx build remixd && nx serve remixd --folder=./apps/remix-ide/contracts --remixide=http://127.0.0.1:8080",