-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes: - add CODEOWNERS - add issue templates - add xcode-install gem - use xcversion for fastlane tests
- Loading branch information
Showing
11 changed files
with
198 additions
and
1 deletion.
There are no files selected for viewing
Validating CODEOWNERS rules …
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* @raccoongang/educationx-app-ios-reviewers |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
name: Bug report for the EducationX IOS app | ||
description: Report any issues that you have found with the EducationX IOS app. Please [check open issues](https://github.com/raccoongang/educationx-app-ios/issues) first, in case it has already been reported. | ||
labels: [Bug] | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Thanks for taking the time to fill out this bug report! | ||
Please report security issues by email to [email protected] | ||
- type: textarea | ||
id: reproduction-steps | ||
attributes: | ||
label: Steps to reproduce | ||
description: Please attach screenshots, videos or logs if you can. | ||
placeholder: Tell us what you see! | ||
value: | | ||
1. Where are you starting? What can you see? | ||
2. What do you click? | ||
3. More steps… | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: result | ||
attributes: | ||
label: Outcome | ||
placeholder: Tell us what went wrong | ||
value: | | ||
#### What did you expect? | ||
#### What happened instead? | ||
validations: | ||
required: true | ||
- type: input | ||
id: device | ||
attributes: | ||
label: Your phone model | ||
placeholder: e.g. iPhoneX | ||
validations: | ||
required: false | ||
- type: input | ||
id: os | ||
attributes: | ||
label: Operating system version | ||
placeholder: e.g. iOS14.7.1, under "software version" | ||
validations: | ||
required: false | ||
- type: input | ||
id: version | ||
attributes: | ||
label: Application version | ||
description: You can find the version information in the Settings of EducationX IOS. | ||
placeholder: | | ||
e.g. Version: v1.2.2 | ||
validations: | ||
required: false |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
blank_issues_enabled: false |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
**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. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: Unit Tests | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
push: | ||
branches: [ develop ] | ||
|
||
pull_request: | ||
|
||
jobs: | ||
tests: | ||
name: Tests | ||
runs-on: macos-13 | ||
|
||
concurrency: | ||
# When running on develop, use the sha to allow all runs of this workflow to run concurrently. | ||
# Otherwise only allow a single run of this workflow on each branch, automatically cancelling older runs. | ||
group: ${{ github.ref == 'refs/heads/develop' && format('unit-tests-develop-{0}', github.sha) || format('unit-tests-{0}', github.ref) }} | ||
cancel-in-progress: true | ||
|
||
steps: | ||
- uses: nschloe/[email protected] | ||
with: | ||
ref: ${{ github.event.pull_request.head.sha }} | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: vendor/bundle | ||
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-gems- | ||
- name: Setup environment | ||
run: | ||
source ci_scripts/ci_prepare_env.sh && setup_github_actions_environment | ||
|
||
- run: | | ||
xcversion installed | ||
- name: SwiftLint | ||
run: | ||
bundle exec fastlane linting | ||
|
||
- name: Run tests | ||
run: bundle exec fastlane unit_tests | ||
|
||
- name: Archive artifacts | ||
uses: actions/upload-artifact@v3 | ||
if: always() | ||
with: | ||
name: test-output | ||
path: fastlane/test_output | ||
retention-days: 7 | ||
if-no-files-found: ignore | ||
|
||
- name: Upload coverage to Codecov | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
flags: unittests |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -98,3 +98,6 @@ iOSInjectionProject/ | |
.DS_Store | ||
.idea | ||
xcode-frameworks | ||
|
||
vendor/ | ||
.bundle/ |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
source "https://rubygems.org" | ||
|
||
gem "fastlane" | ||
gem "xcode-install" |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
#!/bin/sh | ||
|
||
setup_xcode_cloud_environment () { | ||
# Return on failures | ||
# Fail when expanding unset variables | ||
# Trace each command before executing it | ||
set -eEu | ||
|
||
# Move to the project root | ||
cd .. | ||
|
||
# Prevent installing dependencies in system directories | ||
echo 'export GEM_HOME=$HOME/.gem' >>~/.zshrc | ||
echo 'export PATH=$GEM_HOME/bin:$PATH' >>~/.zshrc | ||
echo 'export PATH="/usr/local/opt/[email protected]/bin:$PATH"' >> ~/.zshrc | ||
echo 'export PATH="/Users/local/Library/Python/3.9/bin:$PATH"' >> ~/.zshrc | ||
|
||
export GEM_HOME=$HOME/.gem | ||
export PATH=$GEM_HOME/bin:$PATH | ||
export PATH="/usr/local/opt/[email protected]/bin:$PATH" | ||
export PATH="/Users/local/Library/Python/3.9/bin:$PATH" | ||
|
||
# Things don't work well on the default ruby version | ||
brew install [email protected] | ||
|
||
gem install bundler | ||
|
||
bundle config path vendor/bundle | ||
bundle install --jobs 4 --retry 3 | ||
} | ||
|
||
install_xcode_cloud_brew_dependencies () { | ||
brew update && brew install xcodegen imagemagick | ||
} | ||
|
||
setup_github_actions_environment() { | ||
brew update && brew install xcodegen git-lfs imagemagick | ||
|
||
bundle config path vendor/bundle | ||
bundle install --jobs 4 --retry 3 | ||
|
||
pod install | ||
} |
This file contains 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