From 0076104489785fb2307522f2d96b9111b96268df Mon Sep 17 00:00:00 2001 From: Bruno Michel Date: Tue, 3 Oct 2023 10:55:42 +0200 Subject: [PATCH] Rename integration tests in system tests Integration tests is an expression that covers a lot of different ways to test, depending of the backgrounds of the people that use it. System tests is probably a better term in our case, as it is a less overloaded term. It was inspired by Rails projects. --- .../workflows/{integration.yml => system-tests.yml} | 6 +++--- Makefile | 10 +++++----- cmd/tools.go | 8 ++++---- docs/cli/cozy-stack_tools_encrypt-with-rsa.md | 8 ++++---- model/job/mem_scheduler.go | 8 ++++---- scripts/{integration-test.sh => system-test.sh} | 2 +- tests/{integration => system}/Gemfile | 0 tests/{integration => system}/Gemfile.lock | 0 tests/{integration => system}/README.md | 6 +++--- tests/{integration => system}/boot.rb | 0 tests/{integration => system}/clean.rb | 0 tests/{integration => system}/console.rb | 0 tests/{integration => system}/hammer-runner.sh | 4 ++-- tests/{integration => system}/konnector/index.js | 0 .../konnector/manifest.konnector | 0 tests/{integration => system}/konnector/on_delete.js | 0 tests/{integration => system}/lib/accept.rb | 0 tests/{integration => system}/lib/account.rb | 0 tests/{integration => system}/lib/album.rb | 0 tests/{integration => system}/lib/bitwarden.rb | 0 tests/{integration => system}/lib/bitwarden/cipher.rb | 0 .../lib/bitwarden/organization.rb | 0 tests/{integration => system}/lib/bitwarden/user.rb | 0 tests/{integration => system}/lib/bootstrap.rb | 0 tests/{integration => system}/lib/contact.rb | 0 tests/{integration => system}/lib/couch.rb | 0 tests/{integration => system}/lib/cozy_file.rb | 0 tests/{integration => system}/lib/debug.rb | 0 tests/{integration => system}/lib/email.rb | 0 tests/{integration => system}/lib/export.rb | 0 tests/{integration => system}/lib/folder.rb | 0 tests/{integration => system}/lib/helpers.rb | 0 tests/{integration => system}/lib/import.rb | 0 tests/{integration => system}/lib/instance.rb | 0 tests/{integration => system}/lib/job.rb | 0 tests/{integration => system}/lib/model.rb | 0 tests/{integration => system}/lib/move.rb | 0 tests/{integration => system}/lib/note.rb | 0 tests/{integration => system}/lib/notification.rb | 0 tests/{integration => system}/lib/oauth/client.rb | 2 +- tests/{integration => system}/lib/office.rb | 0 tests/{integration => system}/lib/rule.rb | 0 tests/{integration => system}/lib/settings.rb | 0 tests/{integration => system}/lib/sharing.rb | 0 tests/{integration => system}/lib/stack.rb | 2 +- tests/{integration => system}/lib/test/cat_logs.rb | 0 tests/{integration => system}/lib/test/timeout.rb | 0 tests/{integration => system}/lib/trigger.rb | 0 tests/{integration => system}/parallel-runner.go | 0 .../{integration => system}/scalability/base_tests.rb | 0 .../scalability/inserts_deletes.rb | 0 .../{integration => system}/scalability/large_files.rb | 0 tests/{integration => system}/scalability/random.rb | 0 .../{integration => system}/scalability/recipients.rb | 0 tests/{integration => system}/scalability/sharings.rb | 0 tests/{integration => system}/scalability/trash.rb | 0 tests/{integration => system}/scalability/updates.rb | 0 .../tests/accounts-to-ciphers.rb | 0 .../{integration => system}/tests/accounts_cleaning.rb | 0 tests/{integration => system}/tests/bitwarden_cli.rb | 0 tests/{integration => system}/tests/export_import.rb | 0 tests/{integration => system}/tests/moving_a_cozy.rb | 0 .../{integration => system}/tests/multiple_sharings.rb | 0 tests/{integration => system}/tests/notification.rb | 0 .../tests/onboarding_flagship.rb | 0 tests/{integration => system}/tests/revoke_sharing.rb | 0 tests/{integration => system}/tests/selective_sync.rb | 0 .../tests/sendmail_attachment.rb | 0 .../tests/sharing_moves_n_delete.rb | 0 .../tests/sharing_referenced_by.rb | 0 .../tests/sharing_remove_folder.rb | 0 tests/{integration => system}/tests/trigger_webhook.rb | 0 72 files changed, 28 insertions(+), 28 deletions(-) rename .github/workflows/{integration.yml => system-tests.yml} (96%) rename scripts/{integration-test.sh => system-test.sh} (91%) rename tests/{integration => system}/Gemfile (100%) rename tests/{integration => system}/Gemfile.lock (100%) rename tests/{integration => system}/README.md (96%) rename tests/{integration => system}/boot.rb (100%) rename tests/{integration => system}/clean.rb (100%) rename tests/{integration => system}/console.rb (100%) rename tests/{integration => system}/hammer-runner.sh (62%) rename tests/{integration => system}/konnector/index.js (100%) rename tests/{integration => system}/konnector/manifest.konnector (100%) rename tests/{integration => system}/konnector/on_delete.js (100%) rename tests/{integration => system}/lib/accept.rb (100%) rename tests/{integration => system}/lib/account.rb (100%) rename tests/{integration => system}/lib/album.rb (100%) rename tests/{integration => system}/lib/bitwarden.rb (100%) rename tests/{integration => system}/lib/bitwarden/cipher.rb (100%) rename tests/{integration => system}/lib/bitwarden/organization.rb (100%) rename tests/{integration => system}/lib/bitwarden/user.rb (100%) rename tests/{integration => system}/lib/bootstrap.rb (100%) rename tests/{integration => system}/lib/contact.rb (100%) rename tests/{integration => system}/lib/couch.rb (100%) rename tests/{integration => system}/lib/cozy_file.rb (100%) rename tests/{integration => system}/lib/debug.rb (100%) rename tests/{integration => system}/lib/email.rb (100%) rename tests/{integration => system}/lib/export.rb (100%) rename tests/{integration => system}/lib/folder.rb (100%) rename tests/{integration => system}/lib/helpers.rb (100%) rename tests/{integration => system}/lib/import.rb (100%) rename tests/{integration => system}/lib/instance.rb (100%) rename tests/{integration => system}/lib/job.rb (100%) rename tests/{integration => system}/lib/model.rb (100%) rename tests/{integration => system}/lib/move.rb (100%) rename tests/{integration => system}/lib/note.rb (100%) rename tests/{integration => system}/lib/notification.rb (100%) rename tests/{integration => system}/lib/oauth/client.rb (98%) rename tests/{integration => system}/lib/office.rb (100%) rename tests/{integration => system}/lib/rule.rb (100%) rename tests/{integration => system}/lib/settings.rb (100%) rename tests/{integration => system}/lib/sharing.rb (100%) rename tests/{integration => system}/lib/stack.rb (99%) rename tests/{integration => system}/lib/test/cat_logs.rb (100%) rename tests/{integration => system}/lib/test/timeout.rb (100%) rename tests/{integration => system}/lib/trigger.rb (100%) rename tests/{integration => system}/parallel-runner.go (100%) rename tests/{integration => system}/scalability/base_tests.rb (100%) rename tests/{integration => system}/scalability/inserts_deletes.rb (100%) rename tests/{integration => system}/scalability/large_files.rb (100%) rename tests/{integration => system}/scalability/random.rb (100%) rename tests/{integration => system}/scalability/recipients.rb (100%) rename tests/{integration => system}/scalability/sharings.rb (100%) rename tests/{integration => system}/scalability/trash.rb (100%) rename tests/{integration => system}/scalability/updates.rb (100%) rename tests/{integration => system}/tests/accounts-to-ciphers.rb (100%) rename tests/{integration => system}/tests/accounts_cleaning.rb (100%) rename tests/{integration => system}/tests/bitwarden_cli.rb (100%) rename tests/{integration => system}/tests/export_import.rb (100%) rename tests/{integration => system}/tests/moving_a_cozy.rb (100%) rename tests/{integration => system}/tests/multiple_sharings.rb (100%) rename tests/{integration => system}/tests/notification.rb (100%) rename tests/{integration => system}/tests/onboarding_flagship.rb (100%) rename tests/{integration => system}/tests/revoke_sharing.rb (100%) rename tests/{integration => system}/tests/selective_sync.rb (100%) rename tests/{integration => system}/tests/sendmail_attachment.rb (100%) rename tests/{integration => system}/tests/sharing_moves_n_delete.rb (100%) rename tests/{integration => system}/tests/sharing_referenced_by.rb (100%) rename tests/{integration => system}/tests/sharing_remove_folder.rb (100%) rename tests/{integration => system}/tests/trigger_webhook.rb (100%) diff --git a/.github/workflows/integration.yml b/.github/workflows/system-tests.yml similarity index 96% rename from .github/workflows/integration.yml rename to .github/workflows/system-tests.yml index ec7d7631823..dca96f15168 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/system-tests.yml @@ -1,4 +1,4 @@ -name: Integration tests +name: System tests on: push: branches: @@ -9,7 +9,7 @@ on: paths-ignore: - 'docs/**' jobs: - integration: + system: runs-on: ubuntu-22.04 services: mailhog: @@ -54,4 +54,4 @@ jobs: go install - name: Test run: | - make integration-tests + make system-tests diff --git a/Makefile b/Makefile index 05c9e049add..8da84e50271 100644 --- a/Makefile +++ b/Makefile @@ -30,7 +30,7 @@ scripts/golangci-lint: Makefile ## jslint: enforce a consistent code style for Js code jslint: scripts/node_modules - @scripts/node_modules/.bin/eslint -c scripts/eslintrc.json "assets/scripts/**" tests/integration/konnector/*.js + @scripts/node_modules/.bin/eslint -c scripts/eslintrc.json "assets/scripts/**" tests/system/konnector/*.js .PHONY: jslint ## pretty: make the assets prettier @@ -74,10 +74,10 @@ unit-tests: @go test -p 1 -timeout 2m -short ./... .PHONY: unit-tests -## integration-tests: run the tests -integration-tests: - @scripts/integration-test.sh -.PHONY: integration-tests +## system-tests: run the tests +system-tests: + @scripts/system-test.sh +.PHONY: system-tests ## clean: clean the generated files and directories clean: diff --git a/cmd/tools.go b/cmd/tools.go index 9b701c5241d..ba6efa8c197 100644 --- a/cmd/tools.go +++ b/cmd/tools.go @@ -90,10 +90,10 @@ var encryptRSACmd = &cobra.Command{ Use: "encrypt-with-rsa