-
Notifications
You must be signed in to change notification settings - Fork 61
79 lines (75 loc) · 2.69 KB
/
all-checks.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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: Run all checks on Kedro Starters
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
security-scan:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python ${{inputs.python-version}}
uses: actions/setup-python@v3
with:
python-version: "3.11"
- name: Install test requirements
run: make install-test-requirements
- name: Run Bandit
run: bandit -ll -r .
run-tests:
strategy:
matrix:
os: [ windows-latest , ubuntu-latest ]
python-version: [ "3.8", "3.9", "3.10", "3.11" ]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python ${{matrix.python-version}}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install test requirements
run: |
make install-test-requirements
- name: Add MSBuild to PATH
if: matrix.os == 'windows-latest'
uses: microsoft/setup-msbuild@v1
- name: Install Microsoft Visual C++ Redistributable
if: matrix.os == 'windows-latest'
run: |
choco install vcredist-all
- name: Setup Hadoop binary
if: matrix.os == 'windows-latest'
run: |
Invoke-WebRequest "https://github.com/steveloughran/winutils/blob/master/hadoop-2.7.1/bin/winutils.exe?raw=true" -OutFile winutils.exe
Invoke-WebRequest "https://github.com/steveloughran/winutils/blob/master/hadoop-2.7.1/bin/hadoop.dll?raw=true" -OutFile hadoop.dll
Move-Item .\hadoop.dll C:\Windows\System32
New-Item -ItemType directory -Path C:\hadoop\bin
Move-Item .\winutils.exe C:\hadoop\bin
echo "HADOOP_HOME=C:\hadoop" | Out-File -Append -Encoding ascii -FilePath $env:GITHUB_ENV
echo "PATH=$env:HADOOP_HOME\bin;$env:PATH" | Out-File -Append -Encoding ascii -FilePath $env:GITHUB_ENV
- name: Run `kedro run` end to end tests for all starters
run: |
behave features/run.feature
lint:
strategy:
matrix:
os: [ ubuntu-latest, windows-latest ]
python-version: [ "3.8", "3.9", "3.10", "3.11" ]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python ${{inputs.python-version}}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install test requirements
run: make install-test-requirements
- name: Run linter for all starters
run: behave features/lint.feature