{"id":37027489,"url":"https://github.com/dump247/jupiter-db","last_synced_at":"2026-01-14T03:16:01.980Z","repository":{"id":57726758,"uuid":"342357185","full_name":"dump247/jupiter-db","owner":"dump247","description":"JUnit5 extension that executes each test within a database transaction.","archived":false,"fork":false,"pushed_at":"2021-02-26T18:42:07.000Z","size":113,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-04-14T15:48:24.770Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/dump247.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-02-25T19:32:02.000Z","updated_at":"2021-08-31T18:09:12.000Z","dependencies_parsed_at":"2022-09-26T21:51:00.995Z","dependency_job_id":null,"html_url":"https://github.com/dump247/jupiter-db","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/dump247/jupiter-db","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dump247%2Fjupiter-db","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dump247%2Fjupiter-db/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dump247%2Fjupiter-db/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dump247%2Fjupiter-db/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dump247","download_url":"https://codeload.github.com/dump247/jupiter-db/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dump247%2Fjupiter-db/sbom","scorecard":{"id":359587,"data":{"date":"2025-08-11","repo":{"name":"github.com/dump247/jupiter-db","commit":"26ea331a508c1b3c50b0d6d6b7a131516cc4adf6"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.3,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":9,"reason":"binaries present in source code","details":["Warn: binary detected: gradle/wrapper/gradle-wrapper.jar:1"],"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/build.yml:1","Warn: no topLevel permission defined: .github/workflows/publish-mavencentral.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/dump247/jupiter-db/build.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:16: update your workflow using https://app.stepsecurity.io/secureworkflow/dump247/jupiter-db/build.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/dump247/jupiter-db/build.yml/main?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/build.yml:35: update your workflow using https://app.stepsecurity.io/secureworkflow/dump247/jupiter-db/build.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish-mavencentral.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/dump247/jupiter-db/publish-mavencentral.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish-mavencentral.yml:16: update your workflow using https://app.stepsecurity.io/secureworkflow/dump247/jupiter-db/publish-mavencentral.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish-mavencentral.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/dump247/jupiter-db/publish-mavencentral.yml/main?enable=pin","Info:   0 out of   6 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Eclipse Public License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-18T10:28:00.651Z","repository_id":57726758,"created_at":"2025-08-18T10:28:00.652Z","updated_at":"2025-08-18T10:28:00.652Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28408824,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T01:52:23.358Z","status":"online","status_checked_at":"2026-01-14T02:00:06.678Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":"2026-01-14T03:16:01.251Z","updated_at":"2026-01-14T03:16:01.965Z","avatar_url":"https://github.com/dump247.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"![](https://github.com/dump247/jupiter-db/workflows/Build%20master%20branch/badge.svg)\n![](https://img.shields.io/maven-central/v/com.mostlycertain/jupiter-db-jdbc)\n\n# Jupiter DB Test\n\nTest extension that executes each test within a database transaction. Changes to test data are\nrolled back after the test completes. This helps isolate the tests from each other.\n\n## Usage\n\nAdd a dependency:\n\n```groovy\ntestCompile \"com.mostlycertain:jupiter-db-jdbc:${version}\"\n```\n\nFor jOOQ support, use this dependency instead. The jOOQ library adds support for injecting\na `org.jooq.DSLContext` instance instead of a JDBC connection.\n```groovy\ntestCompile \"com.mostlycertain:jupiter-db-jooq:${version}\"\n```\n\nAdd the `@DatabaseTest` annotation to the test fixture. This loads the extension and gives the\noption to set database connection information. The database connection information is optional\nand can be set or overridden with system properties.\n\nAdd parameters to the test or the test class `@BeforeEach` to inject the database connection.\n\n### Connection Configuration\n\nThe database connection settings (url, user, password) can be completely or partially set using\nthe `@DatabaseTest` annotation. Those values can be set or overridden at runtime using\nsystem properties.\n\nSystem properties:\n- `jupiterdb.database.url` - JDBC connection URL\n- `jupiterdb.database.user` - Database username\n- `jupiterdb.database.password` - Database password\n\n### Initializing Tests\n\nThe extension has annotations that can be used to specify SQL statements to execute before each\ntest runs. This is useful for setting up test data.\n\n#### @InitializeSql\n\nExecute SQL before each test is invoked.\n\nInline SQL can specified with the `value` parameter. Multiple SQL strings can be provided. A single\nSQL string can contain multiple statements, separated by a semicolon.\n\nSQL statements can be loaded from resource files by setting the `resource` parameter to a resource\nfile name. The resource file name is relative to the test class. The file can contain multiple\nstatements, separated by semicolons.\n\nThis annotation can be applied to the test class or individual test methods.\nThe SQL provided is executed on the database connection before each test is run. The SQL\nattached to the test class is executed before the SQL attached to the test method.\n\n#### @FinalizeSql\n\nExecute SQL before each test is invoked, but after all `@InitializeSql` has been executed.\n\nFor example, if you are using postgres, this annotation can be used to switch to a more\nrestricted database role after the database has been initialized.\n\nThe options and usage are the same as `@InitializeSql`.\n\n### Examples\n\n#### Inject the Connection into the Test\n```java\nimport java.sql.Connection;\nimport com.mostlycertain.jupiter.db.DatabaseTest;\n\n@DatabaseTest(\n        url = \"jdbc:postgresql://host/db\",\n        user = \"postgres\",\n        password = \"password\"\n)\nclass FooTest {\n    @Test\n    void test(Connection connection) {\n        // Do some database work\n    }\n}\n```\n\n\n#### Inject the Connection into BeforeEach\n```java\nimport java.sql.Connection;\nimport com.mostlycertain.jupiter.db.DatabaseTest;\n\n@DatabaseTest(\n        url = \"jdbc:postgresql://host/db\",\n        user = \"postgres\",\n        password = \"password\"\n)\nclass FooTest {\n    Connection connection;\n    \n    @BeforeEach\n    void beforeEach(Connection connection) {\n        this.connection = connection;\n    }\n\n    @Test\n    void test() {\n        // Do some database work\n    }\n}\n```\n\n#### Execute SQL\n\n```java\n@DatabaseTest\n@InitializeSql(\"DELETE FROM foo; DELETE from bar\")\n@FinalizeSql(\"SET ROLE service_user\")\nclass FooTest {\n    Connection connection;\n    \n    @BeforeEach\n    void beforeEach(Connection connection) {\n        this.connection = connection;\n    }\n\n    @Test\n    @InitializeSql(resource = \"test_init.sql\")\n    void test() {\n        // Do some database work\n    }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdump247%2Fjupiter-db","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdump247%2Fjupiter-db","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdump247%2Fjupiter-db/lists"}