Skip to content

Commit

Permalink
Merge pull request #9 from Infomaniak/addCI
Browse files Browse the repository at this point in the history
ci: Minimalistic CI running tests on macOS and iOS
  • Loading branch information
adrien-coye authored Nov 14, 2023
2 parents b9f5d87 + 303d167 commit ffceec9
Show file tree
Hide file tree
Showing 5 changed files with 125 additions and 1 deletion.
35 changes: 35 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: bug
assignees: ''

---

<!--Note: English is the preferred language, but if you prefer you can write in French.
L'anglais est la langue préférée, mais si vous préférez, vous pouvez écrire en français.-->

**Description**
A clear and concise description of what the bug is.

**Steps to reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Smartphone (please complete the following information):**
- Device: [e.g. iPhone 12]
- iOS version: [e.g. iOS 14.0]
- App version: [e.g. 4.0.1]

**Additional context**
Add any other context about the problem here.
23 changes: 23 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: enhancement
assignees: ''

---

<!--Note: English is the preferred language, but if you prefer you can write in French.
L'anglais est la langue préférée, mais si vous préférez, vous pouvez écrire en français.-->

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
1 change: 0 additions & 1 deletion .github/workflows/auto-author-assign.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# .github/workflows/auto-author-assign.yml
name: Auto Author Assign

on:
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: CI workflow

on:
pull_request:
branches: [ master ]

jobs:
build_and_test_iOS:
name: Build and Test project on iOS
runs-on: [ self-hosted, iOS ]

steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v2
- name: Build
run: xcodebuild -scheme InfomaniakLogin build -destination "platform=iOS Simulator,name=iPhone 13,OS=latest"
- name: Test
run: xcodebuild -scheme InfomaniakLogin test -destination "platform=iOS Simulator,name=iPhone 13,OS=latest"

build_and_test_macOS:
name: Build and Test project on macOS
runs-on: [ self-hosted, macOS ]

steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v2
- name: Build
run: swift build
- name: Test
run: swift test
29 changes: 29 additions & 0 deletions .github/workflows/semantic-commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: 'PR and Commit Message Check'
on:
pull_request:
types:
- opened
- edited
- reopened
- synchronize
pull_request_target:
types:
- opened
- edited
- reopened
- synchronize

jobs:
check-commit-message:
name: Check Commit Message
runs-on: ubuntu-latest
steps:
- name: Check Commit Message
uses: gsactions/commit-message-checker@v2
with:
pattern: '^(feat|fix|chore|docs|style|refactor|perf|ci|test)(\(.+\))?: [A-Z0-9].+'
error: 'Commit messages and PR title should match conventional commit convention and start with a majuscule.'
excludeDescription: 'true'
excludeTitle: 'false'
checkAllCommitMessages: 'true'
accessToken: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit ffceec9

Please sign in to comment.