awslabs / git-secrets

Prevents you from committing secrets and credentials into git repositories
Apache License 2.0
12.36k stars 1.17k forks source link

Replace bats embed with bats-core submodule #241

Open sparr opened 1 year ago

sparr commented 1 year ago

bats was archived two years ago and bats-core is the active community-maintained fork. This PR is motivated by significantly increased functionality in the newer version, including -f to filter and run specific tests, options to control test output for debugging, additional warnings (which have identified one already-broken test which I'll fix in a PR and link shortly), and much more.

Description of changes: Remove test/bats/* and add a new submodule that checks out https://github.com/bats-core/bats-core to test/bats-core.

Add Makefile target that checks out the submodule if necessary for make test

Relevant doc and comment updates.

Also update test Github workflow to allow manual dispatch.

Also minor formatting updates to CONTRIBUTING.md.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

sparr commented 1 year ago

Failures on tests 21 and 23, and all but one warning, are expected and will be fixed by https://github.com/awslabs/git-secrets/pull/221 Remaining warning will be fixed by #242