-
-
Notifications
You must be signed in to change notification settings - Fork 18
101 lines (94 loc) · 4.51 KB
/
test.yml
File metadata and controls
101 lines (94 loc) · 4.51 KB
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# EndBASIC
# Copyright 2021 Julio Merino
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
# use this file except in compliance with the License. You may obtain a copy
# of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
name: Test
on: push
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
# Use the latest stable Rust version for lint checks to
# verify any new Clippy warnings that may appear.
toolchain: stable
components: clippy, rustfmt
- uses: actions/checkout@v4
- run: sudo apt update
- run: sudo apt install libsdl2-dev libsdl2-ttf-dev
- run: ./.github/workflows/lint.sh
linux-test:
runs-on: ubuntu-latest
env:
SERVICE_URL: ${{ secrets.SERVICE_URL }}
TEST_ACCOUNT_1_USERNAME: ${{ secrets.TEST_ACCOUNT_1_USERNAME }}
TEST_ACCOUNT_1_PASSWORD: ${{ secrets.TEST_ACCOUNT_1_PASSWORD }}
TEST_ACCOUNT_2_USERNAME: ${{ secrets.TEST_ACCOUNT_2_USERNAME }}
TEST_ACCOUNT_2_PASSWORD: ${{ secrets.TEST_ACCOUNT_2_PASSWORD }}
steps:
- uses: actions/checkout@v4
- run: sudo apt update
- run: sudo apt install libsdl2-dev libsdl2-ttf-dev
- run: cargo test --package='*' --features=sdl
-- --include-ignored --skip sdl_console
macos-test:
runs-on: macos-latest
env:
SERVICE_URL: ${{ secrets.SERVICE_URL }}
TEST_ACCOUNT_1_USERNAME: ${{ secrets.TEST_ACCOUNT_1_USERNAME }}
TEST_ACCOUNT_1_PASSWORD: ${{ secrets.TEST_ACCOUNT_1_PASSWORD }}
TEST_ACCOUNT_2_USERNAME: ${{ secrets.TEST_ACCOUNT_2_USERNAME }}
TEST_ACCOUNT_2_PASSWORD: ${{ secrets.TEST_ACCOUNT_2_PASSWORD }}
steps:
- uses: actions/checkout@v4
- run: brew install sdl2 sdl2_ttf
- run: cargo test --package=endbasic-client -- --include-ignored
- run: cargo test --package=endbasic-core -- --include-ignored
- run: cargo test --package=endbasic-std -- --include-ignored
- run: cargo test --package=endbasic-repl -- --include-ignored
- run: LIBRARY_PATH="$LIBRARY_PATH:$(brew --prefix)/lib"
cargo test --package=endbasic-sdl
-- --include-ignored --skip sdl_console
- run: cargo test --package=endbasic-terminal -- --include-ignored
- run: LIBRARY_PATH="$LIBRARY_PATH:$(brew --prefix)/lib"
cargo test --package=endbasic --features=sdl
-- --include-ignored --skip sdl_console
- run: cargo test --package=endbasic-web -- --include-ignored
windows-test:
runs-on: windows-latest
env:
SERVICE_URL: ${{ secrets.SERVICE_URL }}
TEST_ACCOUNT_1_USERNAME: ${{ secrets.TEST_ACCOUNT_1_USERNAME }}
TEST_ACCOUNT_1_PASSWORD: ${{ secrets.TEST_ACCOUNT_1_PASSWORD }}
TEST_ACCOUNT_2_USERNAME: ${{ secrets.TEST_ACCOUNT_2_USERNAME }}
TEST_ACCOUNT_2_PASSWORD: ${{ secrets.TEST_ACCOUNT_2_PASSWORD }}
steps:
- uses: actions/checkout@v4
- run: choco install --allow-empty-checksums unzip
- run: ./.github/workflows/setup-sdl.ps1
- run: cargo test --package=endbasic-client -- --include-ignored
- run: cargo test --package=endbasic-core -- --include-ignored
- run: cargo test --package=endbasic-std -- --include-ignored
- run: cargo test --package=endbasic-repl -- --include-ignored
- run: cargo test --package=endbasic-sdl
-- --include-ignored
- run: cargo test --package=endbasic-terminal -- --include-ignored
- run: cargo test --package=endbasic --features=sdl
-- --include-ignored
- run: cargo test --package=endbasic-web -- --include-ignored
linux-test-no-features:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: cd std && cargo build --no-default-features