run_emqx_app_tests.yaml 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. name: Check emqx app standalone
  2. ## apps/emqx can be used as a rebar/mix dependency
  3. ## in other project, so we need to make sure apps/emqx
  4. ## as an Erlang/Elixir app works standalone
  5. on:
  6. push:
  7. branches:
  8. - '**'
  9. tags:
  10. - v*
  11. - e*
  12. pull_request:
  13. jobs:
  14. check_all:
  15. strategy:
  16. matrix:
  17. otp:
  18. - 23.3.4.9-4
  19. - 24.2.1-1
  20. # no need to use more than 1 version of Elixir, since tests
  21. # run using only Erlang code. This is needed just to specify
  22. # the base image.
  23. elixir:
  24. - 1.13.3
  25. os:
  26. - ubuntu20.04
  27. arch:
  28. - amd64
  29. runs-on: ubuntu-20.04
  30. container: "ghcr.io/emqx/emqx-builder/5.0-8:${{ matrix.elixir}}-${{ matrix.otp }}-${{ matrix.os }}"
  31. steps:
  32. - uses: actions/checkout@v2
  33. - name: Get deps git refs for cache
  34. id: deps-refs
  35. run: |
  36. PATH=$PATH:./ scripts/get-dep-refs.sh
  37. make clean-all
  38. - name: load quicer cache
  39. uses: actions/cache@v2
  40. with:
  41. path: _build/default/lib/quicer/
  42. key: ${{ matrix.os }}-${{ matrix.otp }}-${{ matrix.arch }}-${{ steps.deps-refs.outputs.DEP_QUICER_REF }}
  43. - name: run
  44. run: |
  45. make ensure-rebar3
  46. cp rebar3 apps/emqx/
  47. cd apps/emqx
  48. ./rebar3 xref
  49. ./rebar3 dialyzer
  50. ./rebar3 eunit -v
  51. ./rebar3 ct -v
  52. ./rebar3 proper -d test/props
  53. - uses: actions/upload-artifact@v1
  54. if: failure()
  55. with:
  56. name: logs
  57. path: apps/emqx/_build/test/logs