Skip to content

Commit

Permalink
Fastlane & CI improvements (#321)
Browse files Browse the repository at this point in the history
- tests runs now on each push (also for main branch)
- tests are no more treated as "deployment"

---------

Co-authored-by: Michael Bisgaard Olesen <[email protected]>
  • Loading branch information
milsawicki and bisgardo authored May 26, 2023
1 parent 908dd1a commit 4191412
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 11 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
name: Test

on:
pull_request:
branches:
- main
- feature/*
push:
jobs:
Test:
environment: Mock
runs-on: macos-13

steps:
Expand All @@ -20,4 +16,4 @@ jobs:
SCHEME: ${{ vars.SCHEME }}
APP_IDENTIFIER: ${{ vars.APP_IDENTIFIER }}
SLACK_CHANNEL: ${{ vars.SLACK_CHANNEL }}
SLACK_URL: ${{ vars.SLACK_URL }}
SLACK_URL: ${{ secrets.SLACK_URL }}
10 changes: 5 additions & 5 deletions fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ platform :ios do
devices: ['iPhone 13 Pro'],
code_coverage: true,
scheme: "Mock",
slack_url: ENV['slack_url'],
slack_url: ENV['SLACK_URL'],
slack_channel: ENV['SLACK_CHANNEL']
)
end
Expand Down Expand Up @@ -56,8 +56,8 @@ platform :ios do
def on_success(message)
begin
slack(
slack_url: ENV['slack_url'],
channel: ENV['slack_channel'],
slack_url: ENV['SLACK_URL'],
channel: ENV['SLACK_CHANNEL'],
title: "Success! ✅",
message: message,
facts:[],
Expand All @@ -71,9 +71,9 @@ platform :ios do
def on_error(message)
begin
slack(
slack_url: ENV['slack_url'],
slack_url: ENV['SLACK_URL'],
message: "Sorry! Unfortunately your CI build has failed! 🙁",
channel: ENV['slack_channel'],
channel: ENV['SLACK_CHANNEL'],
success: false,
payload: { "Build Date" => Time.new.to_s },
default_payloads: [:git_branch, :lane, :test_result, :last_git_commit, :last_git_commit_hash]
Expand Down

0 comments on commit 4191412

Please sign in to comment.