Skip to content

Commit

Permalink
Separate test code from production code
Browse files Browse the repository at this point in the history
1. inputs (for CI) are managed by code, not by .yml env. variables
2. rebar3_builds.txt added for stable repeatability
3. tests tweaked to make it easier to modify and drop dependency on production code
4. `dist` regenerated (duplicate files gone)
5. setup-elixir.js tweaked to this new reality
  • Loading branch information
paulo-ferraz-oliveira committed Mar 29, 2021
1 parent d17fed4 commit 4ee73cb
Show file tree
Hide file tree
Showing 20 changed files with 581 additions and 6,093 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ jobs:
node-version: '12'
- run: npm install -g npm
- run: npm install
- run: npm run build
- run: npm run jslint
- run: npm run licenses
- run: npm install -g markdownlint-cli
- run: npm run markdownlint
- run: npm run shellcheck
- run: npm run yamllint
- run: npm run build
- name: Check if build left artifacts
run: git diff --exit-code
5 changes: 0 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@ jobs:
unit_test:
name: Pre-release unit tests
runs-on: ubuntu-latest
env:
CI_TEST_OTP_VSN: '23.2'
CI_TEST_ELIXIR_VSN: '1.11'
CI_TEST_REBAR3_VSN: '3.14'
CI_TEST_ENV: test
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
Expand Down
302 changes: 302 additions & 0 deletions __tests__/rebar3_builds.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,302 @@
[
{
"name": "beta-4",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/beta-4",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/beta-4",
"commit": {
"sha": "356ac5033d12b8b91ed0d6c4d308b00070ab12b9",
"url": "https://api.github.com/repos/erlang/rebar3/commits/356ac5033d12b8b91ed0d6c4d308b00070ab12b9"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2JldGEtNA=="
},
{
"name": "beta-2",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/beta-2",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/beta-2",
"commit": {
"sha": "bfd40d502b429100bab7980c7a0557b6d573e4ce",
"url": "https://api.github.com/repos/erlang/rebar3/commits/bfd40d502b429100bab7980c7a0557b6d573e4ce"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2JldGEtMg=="
},
{
"name": "beta-1",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/beta-1",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/beta-1",
"commit": {
"sha": "4f981061f3ed3a89c2f1fad41601d8adaff9ecc5",
"url": "https://api.github.com/repos/erlang/rebar3/commits/4f981061f3ed3a89c2f1fad41601d8adaff9ecc5"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2JldGEtMQ=="
},
{
"name": "alpha",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/alpha",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/alpha",
"commit": {
"sha": "5ef7d024c30c35e69e4882c1bc847fd46af6901a",
"url": "https://api.github.com/repos/erlang/rebar3/commits/5ef7d024c30c35e69e4882c1bc847fd46af6901a"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2FscGhh"
},
{
"name": "alpha-6",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/alpha-6",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/alpha-6",
"commit": {
"sha": "e09be186c10c113040fd984fa27cbda5581eef0f",
"url": "https://api.github.com/repos/erlang/rebar3/commits/e09be186c10c113040fd984fa27cbda5581eef0f"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2FscGhhLTY="
},
{
"name": "alpha-5",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/alpha-5",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/alpha-5",
"commit": {
"sha": "8642e923c6fd9f1887b3499b3c92069eed875d22",
"url": "https://api.github.com/repos/erlang/rebar3/commits/8642e923c6fd9f1887b3499b3c92069eed875d22"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2FscGhhLTU="
},
{
"name": "alpha-4",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/alpha-4",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/alpha-4",
"commit": {
"sha": "38191c369a29c4cd8f6c5a30233014b7d7547813",
"url": "https://api.github.com/repos/erlang/rebar3/commits/38191c369a29c4cd8f6c5a30233014b7d7547813"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2FscGhhLTQ="
},
{
"name": "alpha-3",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/alpha-3",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/alpha-3",
"commit": {
"sha": "15a7ccfaab4af9da65dfed834a0762d835f6bd2c",
"url": "https://api.github.com/repos/erlang/rebar3/commits/15a7ccfaab4af9da65dfed834a0762d835f6bd2c"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2FscGhhLTM="
},
{
"name": "alpha-2",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/alpha-2",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/alpha-2",
"commit": {
"sha": "61455c04d01b07aa9a12368091259bbb840e836a",
"url": "https://api.github.com/repos/erlang/rebar3/commits/61455c04d01b07aa9a12368091259bbb840e836a"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2FscGhhLTI="
},
{
"name": "alpha-1",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/alpha-1",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/alpha-1",
"commit": {
"sha": "f97d5ab19df1f199e2cad6b3017c7cb017c69ede",
"url": "https://api.github.com/repos/erlang/rebar3/commits/f97d5ab19df1f199e2cad6b3017c7cb017c69ede"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzL2FscGhhLTE="
},
{
"name": "3.14.4",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.14.4",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.14.4",
"commit": {
"sha": "2d443b5c8b9fe5f1beb8027e9c2ca7e5dcc61810",
"url": "https://api.github.com/repos/erlang/rebar3/commits/2d443b5c8b9fe5f1beb8027e9c2ca7e5dcc61810"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTQuNA=="
},
{
"name": "3.14.3",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.14.3",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.14.3",
"commit": {
"sha": "6036581295a6741612dea9eed5277affc5da21d1",
"url": "https://api.github.com/repos/erlang/rebar3/commits/6036581295a6741612dea9eed5277affc5da21d1"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTQuMw=="
},
{
"name": "3.14.2",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.14.2",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.14.2",
"commit": {
"sha": "07fdbf5e2a1126d190cabb19d5d9a2db33f230cf",
"url": "https://api.github.com/repos/erlang/rebar3/commits/07fdbf5e2a1126d190cabb19d5d9a2db33f230cf"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTQuMg=="
},
{
"name": "3.14.1",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.14.1",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.14.1",
"commit": {
"sha": "7b90fafef225fea20e7c1acab6052d28fd9f9edf",
"url": "https://api.github.com/repos/erlang/rebar3/commits/7b90fafef225fea20e7c1acab6052d28fd9f9edf"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTQuMQ=="
},
{
"name": "3.14.0",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.14.0",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.14.0",
"commit": {
"sha": "390421e1c3a76029c611d2f33aff8d8f5b4ea562",
"url": "https://api.github.com/repos/erlang/rebar3/commits/390421e1c3a76029c611d2f33aff8d8f5b4ea562"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTQuMA=="
},
{
"name": "3.14.0-rc2",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.14.0-rc2",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.14.0-rc2",
"commit": {
"sha": "9e6dacc9e51c5fe501b393952a32d379a0041897",
"url": "https://api.github.com/repos/erlang/rebar3/commits/9e6dacc9e51c5fe501b393952a32d379a0041897"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTQuMC1yYzI="
},
{
"name": "3.14.0-rc1",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.14.0-rc1",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.14.0-rc1",
"commit": {
"sha": "11936db9a8ecd0d8d85a7c4c846220fb39bdb3f7",
"url": "https://api.github.com/repos/erlang/rebar3/commits/11936db9a8ecd0d8d85a7c4c846220fb39bdb3f7"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTQuMC1yYzE="
},
{
"name": "3.13.2",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.13.2",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.13.2",
"commit": {
"sha": "73c36138ffbca4851331878791156845047761d2",
"url": "https://api.github.com/repos/erlang/rebar3/commits/73c36138ffbca4851331878791156845047761d2"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTMuMg=="
},
{
"name": "3.13.1",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.13.1",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.13.1",
"commit": {
"sha": "411347618031227b6d2de01112e175876a106e60",
"url": "https://api.github.com/repos/erlang/rebar3/commits/411347618031227b6d2de01112e175876a106e60"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTMuMQ=="
},
{
"name": "3.13.0",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.13.0",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.13.0",
"commit": {
"sha": "e33357af97605f8b2cfffab3e16fc1588165afa1",
"url": "https://api.github.com/repos/erlang/rebar3/commits/e33357af97605f8b2cfffab3e16fc1588165afa1"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTMuMA=="
},
{
"name": "3.12.0",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.12.0",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.12.0",
"commit": {
"sha": "6cf8f2633d1e9e2d1f4c61ab450b57390da8cf66",
"url": "https://api.github.com/repos/erlang/rebar3/commits/6cf8f2633d1e9e2d1f4c61ab450b57390da8cf66"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTIuMA=="
},
{
"name": "3.11.1",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.11.1",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.11.1",
"commit": {
"sha": "2d63f7d273ab9965a70019e1dd94a11a632247b3",
"url": "https://api.github.com/repos/erlang/rebar3/commits/2d63f7d273ab9965a70019e1dd94a11a632247b3"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTEuMQ=="
},
{
"name": "3.11.0",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.11.0",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.11.0",
"commit": {
"sha": "0860d9f9f345574ee46e43379a2bc10e6ac521a3",
"url": "https://api.github.com/repos/erlang/rebar3/commits/0860d9f9f345574ee46e43379a2bc10e6ac521a3"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTEuMA=="
},
{
"name": "3.10.0",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.10.0",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.10.0",
"commit": {
"sha": "1cee74f7306098bb503fe98d55dd270cf712ff42",
"url": "https://api.github.com/repos/erlang/rebar3/commits/1cee74f7306098bb503fe98d55dd270cf712ff42"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuMTAuMA=="
},
{
"name": "3.9.1",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.9.1",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.9.1",
"commit": {
"sha": "df53ad18ff5330660bd102d3a4071cb0962c8dda",
"url": "https://api.github.com/repos/erlang/rebar3/commits/df53ad18ff5330660bd102d3a4071cb0962c8dda"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuOS4x"
},
{
"name": "3.9.0",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.9.0",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.9.0",
"commit": {
"sha": "94bcd31f94bee7c33d642e9d78fc9cf60f7015d0",
"url": "https://api.github.com/repos/erlang/rebar3/commits/94bcd31f94bee7c33d642e9d78fc9cf60f7015d0"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuOS4w"
},
{
"name": "3.8.0",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.8.0",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.8.0",
"commit": {
"sha": "4b6f537df214f91eafd4f15a57058d1e7d247e67",
"url": "https://api.github.com/repos/erlang/rebar3/commits/4b6f537df214f91eafd4f15a57058d1e7d247e67"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuOC4w"
},
{
"name": "3.7.5",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.7.5",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.7.5",
"commit": {
"sha": "b562a893f8967cf8102d1ded8d3d23a66ff1116a",
"url": "https://api.github.com/repos/erlang/rebar3/commits/b562a893f8967cf8102d1ded8d3d23a66ff1116a"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuNy41"
},
{
"name": "3.7.4",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.7.4",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.7.4",
"commit": {
"sha": "0907ccea9a235432118946e51e874e84b7e9a25d",
"url": "https://api.github.com/repos/erlang/rebar3/commits/0907ccea9a235432118946e51e874e84b7e9a25d"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuNy40"
},
{
"name": "3.7.3",
"zipball_url": "https://api.github.com/repos/erlang/rebar3/zipball/3.7.3",
"tarball_url": "https://api.github.com/repos/erlang/rebar3/tarball/3.7.3",
"commit": {
"sha": "fc20a946609a8d1e22686472c47c2896b97eaefa",
"url": "https://api.github.com/repos/erlang/rebar3/commits/fc20a946609a8d1e22686472c47c2896b97eaefa"
},
"node_id": "MDM6UmVmMjY2MTAxMzA6cmVmcy90YWdzLzMuNy4z"
}
]
Loading

0 comments on commit 4ee73cb

Please sign in to comment.