Skip to content

Commit

Permalink
Leverage release candidate
Browse files Browse the repository at this point in the history
  • Loading branch information
Schultzer committed Apr 29, 2024
1 parent 77cfa6d commit 7b50226
Showing 1 changed file with 99 additions and 9 deletions.
108 changes: 99 additions & 9 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
name: Integration
name: test
on: push
env:
MIX_ENV: test
CLDR_BRANCH: ${{ github.ref_name }}
CLDR_PATH: ${{github.workspace}}/${{github.ref_name}}-${{github.run_id}}-${{github.run_number}}-${{github.run_attempt}}
permissions:
contents: read
jobs:
test:
main:
services:
db:
image: postgres:12
Expand All @@ -31,16 +31,106 @@ jobs:
"cldr_person_names", "cldr_plugs", "cldr_print", "cldr_routes",
"cldr_sql", "cldr_strftime", "cldr_territories", "cldr_text",
"cldr_trans", "cldr_units", "cldr_units_sql", "cldr_utils"]
elixir: ["1.12"]
otp: ["22.0"]
runs-on: ubuntu-latest
name: ${{matrix.elixir}}-otp-${{matrix.otp}} ${{matrix.app}}
steps:
- name: Set up elixir ${{matrix.elixir}}-otp-${{matrix.otp}}
uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.otp}}
elixir-version: ${{matrix.elixir}}
- name: Checkout ${{github.repository_owner}}/${{matrix.app}}
uses: actions/checkout@v4
with:
path: ${{matrix.app}}
repository: ${{github.repository_owner}}/${{matrix.app}}
- name: Checkout ${{github.repository}}
uses: actions/checkout@v4
with:
path: ${{github.ref_name}}
repository: ${{github.repository}}
ref: ${{github.ref_name}}

- name: Built release
run: cd ${{github.workspace}}/${{github.ref_name}} && mix hex.build -o ${{env.CLDR_PATH}} --unpack

- name: Install dependencies
run: cd ${{github.workspace}}/${{matrix.app}} && mix deps.get && mix deps.compile

- name: Compiles without warnings
run: cd ${{github.workspace}}/${{matrix.app}} && mix compile --warnings-as-errors

# - name: Check Formatting
# run: mix format --check-formatted

- name: Run tests
run: cd ${{github.workspace}}/${{matrix.app}} && mix test

- name: Run dialyzer
run: cd ${{github.workspace}}/${{matrix.app}} && mix dialyzer
head:
services:
db:
image: postgres:12
ports: ['5432:5432']
env:
POSTGRES_PASSWORD: postgres
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
continue-on-error: true
strategy:
fail-fast: false
matrix:
app: ["cldr_calendars", "cldr_calendars_composite", "cldr_calendars_coptic",
"cldr_calendars_ethiopic", "cldr_calendars_format",
"cldr_calendars_japanese", "cldr_calendars_lunisolar",
"cldr_calendars_persian", "cldr_collation", "cldr_currencies",
"cldr_dates_times", "cldr_html", "cldr_languages", "cldr_lists",
"cldr_locale_display", "cldr_messages", "cldr_numbers",
"cldr_person_names", "cldr_plugs", "cldr_print", "cldr_routes",
"cldr_sql", "cldr_strftime", "cldr_territories", "cldr_text",
"cldr_trans", "cldr_units", "cldr_units_sql", "cldr_utils"]
elixir: ["main"]
otp: ["maint"]
runs-on: ubuntu-latest
name: ${{matrix.app}}
name: ${{matrix.elixir}}-otp-${{matrix.otp}} ${{matrix.app}}
steps:
- uses: actions/checkout@v4
with:
repository: elixir-cldr/${{matrix.app}}
- uses: erlef/setup-beam@v1
- name: Set up elixir ${{matrix.elixir}}-otp-${{matrix.otp}}
uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.otp}}
elixir-version: ${{matrix.elixir}}
- run: mix deps.get && mix deps.compile && mix compile --warnings-as-errors && mix test
- name: Checkout ${{github.repository_owner}}/${{matrix.app}}
uses: actions/checkout@v4
with:
path: ${{matrix.app}}
repository: ${{github.repository_owner}}/${{matrix.app}}
- name: Checkout ${{github.repository}}
uses: actions/checkout@v4
with:
path: ${{github.ref_name}}
repository: ${{github.repository}}
ref: ${{github.ref_name}}

- name: Built release
run: cd ${{github.workspace}}/${{github.ref_name}} && mix hex.build -o ${{env.CLDR_PATH}} --unpack

- name: Install dependencies
run: cd ${{github.workspace}}/${{matrix.app}} && mix deps.get && mix deps.compile

- name: Compiles without warnings
run: cd ${{github.workspace}}/${{matrix.app}} && mix compile --warnings-as-errors

# - name: Check Formatting
# run: mix format --check-formatted

- name: Run tests
run: cd ${{github.workspace}}/${{matrix.app}} && mix test

- name: Run dialyzer
run: cd ${{github.workspace}}/${{matrix.app}} && mix dialyzer

0 comments on commit 7b50226

Please sign in to comment.