{"id":15046211,"url":"https://github.com/mig4/setup-bats","last_synced_at":"2025-10-26T07:31:25.333Z","repository":{"id":35518974,"uuid":"217765165","full_name":"mig4/setup-bats","owner":"mig4","description":"GitHub Action to setup BATS testing framework","archived":false,"fork":false,"pushed_at":"2023-01-16T20:01:48.000Z","size":1427,"stargazers_count":27,"open_issues_count":20,"forks_count":9,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-28T13:48:05.566Z","etag":null,"topics":["action","bats","github-action","github-actions","hacktoberfest","setup","testing","testing-framework"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mig4.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":"2019-10-26T20:24:44.000Z","updated_at":"2024-04-30T20:13:37.000Z","dependencies_parsed_at":"2023-01-16T23:01:35.156Z","dependency_job_id":null,"html_url":"https://github.com/mig4/setup-bats","commit_stats":{"total_commits":144,"total_committers":3,"mean_commits":48.0,"dds":"0.11111111111111116","last_synced_commit":"2859ea733ef81b6ba31008a7fba0cacfbf2a5429"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":"actions/typescript-action","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mig4%2Fsetup-bats","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mig4%2Fsetup-bats/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mig4%2Fsetup-bats/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mig4%2Fsetup-bats/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mig4","download_url":"https://codeload.github.com/mig4/setup-bats/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237547542,"owners_count":19327871,"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":["action","bats","github-action","github-actions","hacktoberfest","setup","testing","testing-framework"],"created_at":"2024-09-24T20:52:51.716Z","updated_at":"2025-10-26T07:31:20.016Z","avatar_url":"https://github.com/mig4.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![tag-badge][]]() [![CI][ci-badge]][ci-target]\n\n# Setup BATS 🦇\n\nA :octocat: GitHub Action to setup [BATS testing framework][bats].\n\n## Usage 🚀\n\nA sample workflow to run tests using [BATS][] (`.github/workflows/ci.yml`):\n\n``` yaml\nname: \"CI\"\non: [push, pull_request]\njobs:\n  build:\n    name: build\n    runs-on: ubuntu-latest\n    steps:\n\n      - name: Setup BATS\n        uses: mig4/setup-bats@v1\n        with:\n          bats-version: 1.2.1\n\n      - name: Check out code\n        uses: actions/checkout@v1\n\n      - name: Test\n        run: bats -r .\n```\n\n### Options 🎨\n\nOptions available as keys in `with` block\n\n- `bats-version` (`string`): version of [BATS][] to setup, defaults to 1.2.1 if\n  not set\n\n## Platforms 🖥\n\nSo far this action has only been tested on Linux [environments](https://help.github.com/en/articles/virtual-environments-for-github-actions#supported-virtual-environments-and-hardware-resources).\n\n## Contributing 🤝\n\nSee known [issues](https://github.com/mig4/setup-bats/issues), if you found\none that's not on the list or have a suggestion for improvement, open a new\nissue. If you can, fork and send a PR, it will be appreciated 💖.\n\n### Hacking 🧰\n\n#### Building\n\nInstall the dependencies  \n\n``` bash\n$ npm install\n```\n\nBuild the typescript, apply formatting, lint and package the code for\ndistribution and run unit tests:\n\n```bash\n$ npm run all\n```\n\nRun the tests separately :heavy_check_mark:  \n\n```bash\n$ npm test\n...\n PASS  __tests__/installer.test.ts\n  installer tests\n    ✓ Acquires version of BATS if no matching version is installed (1051ms)\n    ✓ Throws if no matching version of BATS can be found (674ms)\n```\n\n#### Code\n\nThe `action.yml` file defines the inputs and output, description, etc. of the\naction.\n\nSee the documentation:\n\n- [Metadata syntax](https://help.github.com/en/articles/metadata-syntax-for-github-actions)\n- [Toolkit](https://github.com/actions/toolkit/blob/master/README.md#packages)\n\n#### Publishing to a distribution branch\n\nActions are run from GitHub repos so the branch which will be used at runtime\nneeds to have the `dist/` folder checked-in. It's recommended for users to only\nrefer to released versions instead of consuming master directly.\n\nThe distribution is created with [ncc](https://github.com/zeit/ncc) which can\nbe invoked via:\n\n``` bash\n$ npm run package\n$ git add dist\n$ git commit -a -m \"prod package\"\n```\n\nNow to release a new minor/patch versions (replace `.x.y` as appropriate):\n\n``` bash\n# update \"version\" property in `package.json`\n$ npm install\n$ npm run all\n$ git add -A\n$ git commit -v -m \"Release v1.x.y\"\n$ git push\n$ git tag -s v1.x.y\n$ git tag -fs v1 -m \"Update v1 tag\"\n$ git push --tags --force\n```\n\nFor the tag to be published to marketplace you need to create a release from\nit which you can do by going into _Releases_ in GitHub UI, then _Tags_ and\nclicking the menu next to the newly created tag and select _Create release_.\nAlternatively use the URL (replace `x.y` as appropriate):\nhttps://github.com/mig4/setup-bats/releases/new?tag=v1.x.y\n\nThe action is now published! :rocket: \n\nSee the [versioning documentation](https://github.com/actions/toolkit/blob/master/docs/action-versioning.md)\n\n## Acknowledgements 👍\n\n* [typescript-action](https://github.com/actions/typescript-action) template\n* [existing setup actions](https://github.com/actions?utf8=%E2%9C%93\u0026q=setup\u0026type=\u0026language=)\n\n## License 📝\n\n[![license-badge][]](LICENSE)\n\n\n[tag-badge]: https://img.shields.io/github/v/tag/mig4/setup-bats\n[ci-badge]: https://github.com/mig4/setup-bats/workflows/CI/badge.svg\n[ci-target]: https://github.com/mig4/setup-bats/actions?workflow=CI\n[bats]: https://github.com/bats-core/bats-core\n[license-badge]: https://img.shields.io/github/license/mig4/setup-bats?style=for-the-badge\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmig4%2Fsetup-bats","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmig4%2Fsetup-bats","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmig4%2Fsetup-bats/lists"}