-
Notifications
You must be signed in to change notification settings - Fork 0
56 lines (48 loc) · 1.7 KB
/
Copy pathci.yml
File metadata and controls
56 lines (48 loc) · 1.7 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
name: CI
on:
push:
branches: [main]
pull_request:
workflow_dispatch:
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- run: bun install --frozen-lockfile
- run: bun run typecheck
- run: bun test
- run: bun run check-formatting
- name: dist/ is up to date
run: |
bun run build
if ! git diff --quiet -- dist/; then
echo "::error::dist/ is stale - run 'bun run build' and commit the result"
git diff -- dist/
exit 1
fi
e2e:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Cache Blockbench
uses: actions/cache@v4
with:
path: ~/.envbench
key: envbench-${{ runner.os }}-blockbench-latest
- name: Run the action against the test fixtures
id: build
uses: ./
with:
blueprints-path: test/fixtures/models
- name: Check results
env:
EXPORTED: ${{ steps.build.outputs.exported-count }}
FAILED: ${{ steps.build.outputs.failed-count }}
run: |
echo "exported=$EXPORTED failed=$FAILED"
test "$EXPORTED" = "1"
test "$FAILED" = "0"
test -f test/fixtures/datapack/data/aj/function/armor_stand/summon.mcfunction
test -d test/fixtures/resourcepack/assets/aj/models/blueprint/armor_stand