add tests #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Tests | |
| on: | |
| push | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - run: npm ci | |
| - name: Install Swift | |
| run: | | |
| curl -O https://download.swift.org/swiftly/linux/swiftly-$(uname -m).tar.gz && \ | |
| tar zxf swiftly-$(uname -m).tar.gz && \ | |
| ./swiftly init --quiet-shell-followup && \ | |
| . "${SWIFTLY_HOME_DIR:-$HOME/.local/share/swiftly}/env.sh" && \ | |
| hash -r | |
| - name: Configure Swift | |
| run: | | |
| swiftly install 6.2 && \ | |
| swiftly use 6.2 && \ | |
| swift sdk install https://download.swift.org/swift-6.2-release/wasm/swift-6.2-RELEASE/swift-6.2-RELEASE_wasm.artifactbundle.tar.gz --checksum fe4e8648309fce86ea522e9e0d1dc48e82df6ba6e5743dbf0c53db8429fb5224 | |
| - name: Build | |
| run: npm run build | |
| - name: Test | |
| run: npm run test |