-
Notifications
You must be signed in to change notification settings - Fork 4
35 lines (32 loc) · 1.11 KB
/
ci.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
name: CI workflow
on:
pull_request:
branches: [ master ]
jobs:
build:
name: Build and Test project
runs-on: [ self-hosted, iOS ]
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}
- uses: jdx/mise-action@v2
with:
cache: false
- name: Checkout
uses: actions/checkout@v4
- name: Create test env
env:
ENV_PATH: "MailTests/Env.swift"
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}
USER_ID: ${{ secrets.USER_ID }}
MAILBOX_ID: ${{ secrets.MAILBOX_ID }}
MAILBOX_UUID: ${{ secrets.MAILBOX_UUID }}
run: |
touch $ENV_PATH
echo -e "enum Env {\n static let token = \"$ACCESS_TOKEN\"\n static let userId = $USER_ID\n static let mailboxId = $MAILBOX_ID\n static let mailboxUuid = \"$MAILBOX_UUID\"\n}" > $ENV_PATH
- name: Build
run: tuist install && tuist build --clean "Infomaniak Mail"
- name: Unit and Integration Tests
run: tuist test Mail-Workspace --skip-ui-tests