forked from opensearch-project/security-dashboards-plugin
-
Notifications
You must be signed in to change notification settings - Fork 10
39 lines (31 loc) · 1.05 KB
/
unit-test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Unit Tests
on: [push, pull_request]
jobs:
unit-tests:
name: Run unit tests
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest] # Removed windows-latest, macos-latest
runs-on: ${{ matrix.os }}
steps:
# - name: Enable longer filenames
# if: ${{ matrix.os == 'windows-latest' }}
# run: git config --system core.longpaths true
- name: Checkout Branch
uses: actions/checkout@v4
- id: install-dashboards
uses: derek-ho/setup-opensearch-dashboards@v3
with:
plugin_name: wazuh-security-dashboards-plugin
app_reference: ${{ vars.WZD_REF }}
- name: Run lint
run: yarn lint
working-directory: ${{ steps.install-dashboards.outputs.plugin-directory }}
- name: Run unit test
run: yarn test:jest_ui --coverage
working-directory: ${{ steps.install-dashboards.outputs.plugin-directory }}
- name: Uploads coverage
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}