Skip to content

Commit a257c44

Browse files
authored
Merge branch 'master' into release
2 parents ba4a046 + cd124c0 commit a257c44

File tree

116 files changed

+3156
-1806
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+3156
-1806
lines changed

.codeclimate.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
version: "2"
2+
exclude_patterns:
3+
- ".*/"
4+
- "build/"
5+
- "host-app/"
6+
- "images/"
7+
- "inbox-ui-tests-app/"
8+
- "sample-apps/"
9+
- "scripts/"
10+
- "swift-sdk/Resources/"
11+
- "swift-sdk/Internal/Dwifft"
12+
- "tests/"
13+
- "ui-tests-app/"
14+
- "**/.*"
15+
- "**/*.h"
16+
- "**/*.md"
17+
- "**/*.plist"
18+
- "**/*.podspec"
19+
- "**/*.xcodeproj"
20+
- "**/*.yml"
21+
- "Package.swift"
22+
plugins:
23+
tailor:
24+
enabled: true
25+
checks:
26+
trailing-whitespace:
27+
enabled: false
28+
checks:
29+
argument-count:
30+
enabled: true
31+
config:
32+
threshold: 4
33+
complex-logic:
34+
enabled: true
35+
config:
36+
threshold: 4
37+
file-lines:
38+
enabled: true
39+
config:
40+
threshold: 250
41+
method-complexity:
42+
enabled: true
43+
config:
44+
threshold: 5
45+
method-count:
46+
enabled: true
47+
config:
48+
threshold: 20
49+
method-lines:
50+
enabled: true
51+
config:
52+
threshold: 25
53+
nested-control-flow:
54+
enabled: true
55+
config:
56+
threshold: 4
57+
return-statements:
58+
enabled: true
59+
config:
60+
threshold: 4
61+
similar-code:
62+
enabled: true
63+
config:
64+
threshold: 40
65+
identical-code:
66+
enabled: true
67+
config:
68+
threshold: 40

.github/workflows/build-and-test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Build and test
33
on: pull_request
44

55
jobs:
6-
build:
6+
run-tests-job:
77
runs-on: macos-latest
88

99
steps:

.github/workflows/e2e.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Integration Testing
2+
3+
on: pull_request
4+
5+
jobs:
6+
run-e2e-job:
7+
runs-on: macos-latest
8+
9+
steps:
10+
- uses: actions/checkout@v2
11+
12+
- uses: maxim-lobanov/[email protected]
13+
with:
14+
xcode-version: 12.0
15+
16+
- name: Build and test
17+
env:
18+
api_key: ${{secrets.E2E_API_KEY}}
19+
push_campaign_id: ${{secrets.E2E_PUSH_CAMPAIGN_ID}}
20+
push_template_id: ${{secrets.E2E_PUSH_TEMPLATE_ID}}
21+
in_app_campaign_id: ${{secrets.E2E_IN_APP_CAMPAIGN_ID}}
22+
in_app_template_id: ${{secrets.E2E_IN_APP_TEMPLATE_ID}}
23+
run: |
24+
./tests/endpoint-tests/scripts/run_test.sh
25+

.gitignore

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,8 @@ Pods/
1212

1313
dev.config
1414

15-
Build/
15+
Build/
16+
17+
# needed integration testing
18+
env_vars.sh
19+
CI.swift

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
osx_image: xcode11.3
1+
osx_image: xcode12
22
language: swift
33

44
# if debugging this script, don't forget to check the environment vars on https://travis-ci.com/Iterable/swift-sdk/settings

BETA-TOS.md

Lines changed: 0 additions & 16 deletions
This file was deleted.

LICENSE renamed to LICENSE.md

File renamed without changes.

README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![Iterable logo](./images/Iterable-Logo.png "Iterable Logo")
1+
![Iterable logo](https://raw.githubusercontent.com/Iterable/swift-sdk/master/images/Iterable-Logo.png "Iterable Logo")
22

33
[![License](https://img.shields.io/github/license/Iterable/swift-sdk)](https://opensource.org/licenses/MIT)
44
[![Build Status](https://travis-ci.com/Iterable/swift-sdk.svg?branch=master)](https://travis-ci.com/Iterable/swift-sdk)
@@ -52,8 +52,9 @@ Release notes:
5252

5353
Support policies:
5454

55-
- Iterable's [Mobile SDK Support Policy](https://support.iterable.com/hc/articles/360027798391#mobile-sdk-support-policy)
56-
- Iterable's [iOS SDK Deprecation and End-of-Life Schedule](https://support.iterable.com/hc/articles/360027798391#ios-sdk-deprecation-and-end-of-life-schedule)
55+
- Iterable's [Mobile SDK Support Policy](https://support.iterable.com/hc/articles/360046136171)
56+
- Iterable's [iOS SDK Deprecation and End-of-Life Schedule](https://support.iterable.com/hc/articles/360027798391#deprecation-and-end-of-life-schedule)
57+
- Iterable's [Beta Mobile SDK Disclaimer](https://support.iterable.com/hc/articles/360034753412)
5758

5859
Troubleshooting:
5960

@@ -65,7 +66,7 @@ Please contact your customer success manager with any questions.
6566

6667
## License
6768

68-
This SDK is released under the MIT License. See [LICENSE](https://github.com/Iterable/swift-sdk/blob/master/LICENSE?raw=true)
69+
This SDK is released under the MIT License. See [LICENSE](https://github.com/Iterable/swift-sdk/blob/master/LICENSE.md)
6970
for more information.
7071

7172
## Want to contribute?

host-app/AppDelegate.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
1717

1818
func application(_: UIApplication, didFinishLaunchingWithOptions _: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
1919
// Override point for customization after application launch.
20-
return true
20+
true
2121
}
2222

2323
func applicationWillResignActive(_: UIApplication) {

inbox-ui-tests-app/AppDelegate.swift

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import UserNotifications
1111
@UIApplicationMain
1212
class AppDelegate: UIResponder, UIApplicationDelegate {
1313
static var sharedInstance: AppDelegate {
14-
return UIApplication.shared.delegate as! AppDelegate
14+
UIApplication.shared.delegate as! AppDelegate
1515
}
1616

1717
var window: UIWindow?
@@ -33,10 +33,11 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
3333
let config = IterableConfig()
3434
config.customActionDelegate = self
3535
config.urlDelegate = self
36-
TestHelper.getTestUserDefaults().set("[email protected]", forKey: Const.UserDefaults.emailKey)
37-
36+
let localStorage = MockLocalStorage()
37+
localStorage.email = "[email protected]"
3838
IterableAPI.initializeForTesting(config: config,
3939
networkSession: mockNetworkSession,
40+
localStorage: localStorage,
4041
inAppFetcher: mockInAppFetcher,
4142
urlOpener: AppUrlOpener())
4243

0 commit comments

Comments
 (0)