{"id":28406739,"url":"https://github.com/eclipse-ditto/ditto-testing","last_synced_at":"2025-06-29T09:32:48.558Z","repository":{"id":119017736,"uuid":"595964654","full_name":"eclipse-ditto/ditto-testing","owner":"eclipse-ditto","description":"Eclipse Ditto™: Digital Twin framework - Testing repository","archived":false,"fork":false,"pushed_at":"2025-06-20T14:29:45.000Z","size":862,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-06-20T15:36:31.014Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"epl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eclipse-ditto.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-02-01T07:08:39.000Z","updated_at":"2025-06-20T14:29:51.000Z","dependencies_parsed_at":"2023-10-15T17:37:47.580Z","dependency_job_id":"4060620d-f810-443f-a152-980339d99b4e","html_url":"https://github.com/eclipse-ditto/ditto-testing","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/eclipse-ditto/ditto-testing","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-ditto%2Fditto-testing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-ditto%2Fditto-testing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-ditto%2Fditto-testing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-ditto%2Fditto-testing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eclipse-ditto","download_url":"https://codeload.github.com/eclipse-ditto/ditto-testing/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-ditto%2Fditto-testing/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262569834,"owners_count":23330288,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-06-01T22:36:44.639Z","updated_at":"2025-06-29T09:32:48.548Z","avatar_url":"https://github.com/eclipse-ditto.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Eclipse Ditto™ Testing\n\nThis repository contains the \"system tests\" of Eclipse Ditto.  \nThey ensure that on API level no regressions happen, that APIs stay stable and that added functionality is tested \nfrom a user perspective.\n\n## How to run tests in IntelliJ\n\nSystem tests require the following components to run.\n1. Containers required by Ditto stack (MongoDB) and by connectivity tests (Mosquitto, Artemis etc.).\n2. A working Ditto stack, either as docker stack or launched from IntelliJ.\n3. A local [authorization server mock](#authorization-server-mock).\n\n### Start MongoDB and message broker containers\n\nIf you want to launch Ditto from IntelliJ, start the MongoDB container:\n```bash\ncd docker\ndocker-compose up -d mongodb\n```\nIf you want to run Ditto as a docker stack, simply run `docker/start.sh`. MongoDB is included.\n\nConnectivity tests require message brokers. Start them thus:\n```bash\ncd docker\n\n# AMQP broker\ndocker-compose up -d artemis\n\n# MQTT broker\ndocker-compose up -d mqtt\n\n# Kafka broker\ndocker-compose up -d kafka\n\n# RabbitMQ broker\ndocker-compose up -d rabbitmq\n```\nThe brokers do consume system resources. Start them on a by-need basis.\n\n### Run Ditto\n\nTo run Ditto as a docker stack, simply execute `docker/start.sh`. MongoDB is included.\n\nTo launch Ditto from IntelliJ, in debug mode for instance, run \n[`Policies`](intelliJRunConfigurations/Policies%20for%20test.run.xml) first and the other required\nservices after. A launch sequence could look like this:\n1. [`Policies`](intelliJRunConfigurations/Policies%20for%20test.run.xml)\n2. [`Things`](intelliJRunConfigurations/Things%20for%20test.run.xml)\n3. [`Search`](intelliJRunConfigurations/ThingsSearch%20for%20test.run.xml)\n4. [`Connectivity`](intelliJRunConfigurations/Connectivity%20for%20test.run.xml)\n5. [`Gateway`](intelliJRunConfigurations/Gateway%20for%20test.run.xml)\n\nOr, simply make use of the [multirun plugin](https://plugins.jetbrains.com/plugin/7248-multirun) for which a \n[run configuration](intelliJRunConfigurations/Ditto4test.run.xml) also is available.\n\n## Authorization server mock\n\nTests authenticate themselves via OAuth against a mock server.  \nThe tests make use of the [mock-oauth2-server](https://github.com/navikt/mock-oauth2-server).\n\nIn order to run it, simply start it via compose:\n```bash\ncd docker\n\n# OAuth mock server\ndocker-compose up -d oauth\n```\n\n# Acceptance tests\nA subset of the system tests, called `Acceptance tests`, could be run against remote Ditto deployment.\nThese need some environment variables set before execution, depending on authentication method configured in Ditto deployment.\nThe following variables must be set:\n\n   * for BasicAuth:\n```\n      BASIC_AUTH_ENABLED = true     # boolean to configure tests\n      DEFAULT_HOSTNAME              # the hostname of the Ditto deployment\n      BASIC_AUTH_USERNAME           # Ditto username for basic auth\n      BASIC_AUTH_PASSWORD           # the password for the user\n```\n  * for OAuth - the tests need an OAuth provider and 4 separate OAuth clients:\n```\n      BASIC_AUTH_ENABLED = false  # default value, could be skipped\n      DEFAULT_HOSTNAME            # the hostname of the Ditto deployment\n\n      OAUTH_TOKEN_ENDPOINT        # OAuth token endpoint for getting tokens\n      OAUTH_ISSUER                # should match the value configured in Ditto\n\n      OAUTH_CLIENT_ID             # main client id\n      OAUTH_CLIENT_SECRET         # main client secret\n      OAUTH_CLIENT_SCOPE          # main client scope\n\n      OAUTH_CLIENT2_ID            # 2nd client id\n      OAUTH_CLIENT2_SECRET        # 2nd client secret\n      OAUTH_CLIENT2_SCOPE         # 2nd client scope\n\n      OAUTH_CLIENT3_ID            # 3rd client id\n      OAUTH_CLIENT3_SECRET        # 3rd client secret\n      OAUTH_CLIENT3_SCOPE         # 3rd client scope\n\n      OAUTH_CLIENT4_ID            # 4th client id\n      OAUTH_CLIENT4_SECRET        # 4th client secret\n      OAUTH_CLIENT4_SCOPE         # 4th client scope\n```\nRun maven with profile `acceptance` and set property `test.environment=deployment`, e.g. with the following command:\n```\nmvn verify -am -amd --projects=system -Pacceptance -Dtest.environment=deployment -Dtest.timeoutMs=240000 -Dskip.categories=ServiceBus\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feclipse-ditto%2Fditto-testing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feclipse-ditto%2Fditto-testing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feclipse-ditto%2Fditto-testing/lists"}