From eff62f8129fb83ea6e40aa60274ec883366b4d93 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 13:34:12 +0100
Subject: [PATCH 01/12] Remove deprecated file for swift version
---
.swift-version | 1 -
1 file changed, 1 deletion(-)
delete mode 100644 .swift-version
diff --git a/.swift-version b/.swift-version
deleted file mode 100644
index 819e07a2..00000000
--- a/.swift-version
+++ /dev/null
@@ -1 +0,0 @@
-5.0
From 7c66e23d9334c9e1cc6ab77071f8afdb0fc30c89 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 15:08:12 +0100
Subject: [PATCH 02/12] Update Copyright date
---
LICENSE.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/LICENSE.md b/LICENSE.md
index 21660f30..20cc288d 100644
--- a/LICENSE.md
+++ b/LICENSE.md
@@ -1,6 +1,6 @@
MIT License
-Copyright (c) 2017-2019 MessageKit
+Copyright (c) 2017-2020 MessageKit
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
From bc7ba72a52a4f109c783a87efb98c2bc5085b3fa Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 15:13:14 +0100
Subject: [PATCH 03/12] Drop iOS 9 and iOS 10
---
MessageKit.podspec | 4 ++--
MessageKit.xcodeproj/project.pbxproj | 6 ++----
.../MessagesViewController+Keyboard.swift | 20 +-----------------
.../Controllers/MessagesViewController.swift | 21 ++++++-------------
4 files changed, 11 insertions(+), 40 deletions(-)
diff --git a/MessageKit.podspec b/MessageKit.podspec
index cd49bca1..dfe3a5a0 100644
--- a/MessageKit.podspec
+++ b/MessageKit.podspec
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'MessageKit'
- s.version = '3.1.0-beta.1'
+ s.version = '3.1.0'
s.license = { :type => "MIT", :file => "LICENSE.md" }
s.summary = 'An elegant messages UI library for iOS.'
@@ -13,7 +13,7 @@ Pod::Spec.new do |s|
s.swift_version = '5.0'
- s.ios.deployment_target = '9.0'
+ s.ios.deployment_target = '11.0'
s.ios.resource_bundle = { 'MessageKitAssets' => 'Assets/MessageKitAssets.bundle/Images' }
s.dependency 'InputBarAccessoryView', '~> 4.3.0'
diff --git a/MessageKit.xcodeproj/project.pbxproj b/MessageKit.xcodeproj/project.pbxproj
index 72509f16..f057f989 100644
--- a/MessageKit.xcodeproj/project.pbxproj
+++ b/MessageKit.xcodeproj/project.pbxproj
@@ -783,7 +783,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -838,7 +838,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_VERSION = 5.0;
@@ -865,7 +865,6 @@
GCC_WARN_ABOUT_DEPRECATED_FUNCTIONS = YES;
INFOPLIST_FILE = "$(SRCROOT)/Sources/Supporting/Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks $(FRAMEWORK_SEARCH_PATHS)";
PRODUCT_BUNDLE_IDENTIFIER = com.messagekit.MessageKit;
PRODUCT_NAME = "$(TARGET_NAME)";
@@ -891,7 +890,6 @@
GCC_WARN_ABOUT_DEPRECATED_FUNCTIONS = YES;
INFOPLIST_FILE = "$(SRCROOT)/Sources/Supporting/Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks $(FRAMEWORK_SEARCH_PATHS)";
PRODUCT_BUNDLE_IDENTIFIER = com.messagekit.MessageKit;
PRODUCT_NAME = "$(TARGET_NAME)";
diff --git a/Sources/Controllers/MessagesViewController+Keyboard.swift b/Sources/Controllers/MessagesViewController+Keyboard.swift
index 2abbd030..223c3efe 100644
--- a/Sources/Controllers/MessagesViewController+Keyboard.swift
+++ b/Sources/Controllers/MessagesViewController+Keyboard.swift
@@ -32,7 +32,6 @@ internal extension MessagesViewController {
func addKeyboardObservers() {
NotificationCenter.default.addObserver(self, selector: #selector(MessagesViewController.handleKeyboardDidChangeState(_:)), name: UIResponder.keyboardWillChangeFrameNotification, object: nil)
NotificationCenter.default.addObserver(self, selector: #selector(MessagesViewController.handleTextViewDidBeginEditing(_:)), name: UITextView.textDidBeginEditingNotification, object: nil)
- NotificationCenter.default.addObserver(self, selector: #selector(MessagesViewController.adjustScrollViewTopInset), name: UIDevice.orientationDidChangeNotification, object: nil)
}
func removeKeyboardObservers() {
@@ -105,19 +104,6 @@ internal extension MessagesViewController {
// MARK: - Inset Computation
- @objc
- func adjustScrollViewTopInset() {
- if #available(iOS 11.0, *) {
- // No need to add to the top contentInset
- } else {
- let navigationBarInset = navigationController?.navigationBar.frame.height ?? 0
- let statusBarInset: CGFloat = UIApplication.shared.isStatusBarHidden ? 0 : 20
- let topInset = navigationBarInset + statusBarInset
- messagesCollectionView.contentInset.top = topInset
- messagesCollectionView.scrollIndicatorInsets.top = topInset
- }
- }
-
private func requiredScrollViewBottomInset(forKeyboardFrame keyboardFrame: CGRect) -> CGFloat {
// we only need to adjust for the part of the keyboard that covers (i.e. intersects) our collection view;
// see https://developer.apple.com/videos/play/wwdc2017/242/ for more details
@@ -142,11 +128,7 @@ internal extension MessagesViewController {
///
/// - Returns: The distance automatically added to contentInset.bottom, if any.
private var automaticallyAddedBottomInset: CGFloat {
- if #available(iOS 11.0, *) {
- return messagesCollectionView.adjustedContentInset.bottom - messagesCollectionView.contentInset.bottom
- } else {
- return 0
- }
+ return messagesCollectionView.adjustedContentInset.bottom - messagesCollectionView.contentInset.bottom
}
}
diff --git a/Sources/Controllers/MessagesViewController.swift b/Sources/Controllers/MessagesViewController.swift
index e74b0183..522997ed 100644
--- a/Sources/Controllers/MessagesViewController.swift
+++ b/Sources/Controllers/MessagesViewController.swift
@@ -130,13 +130,10 @@ UICollectionViewDelegateFlowLayout, UICollectionViewDataSource {
addKeyboardObservers()
messageCollectionViewBottomInset = requiredInitialScrollViewBottomInset()
}
- adjustScrollViewTopInset()
}
open override func viewSafeAreaInsetsDidChange() {
- if #available(iOS 11.0, *) {
- super.viewSafeAreaInsetsDidChange()
- }
+ super.viewSafeAreaInsetsDidChange()
messageCollectionViewBottomInset = requiredInitialScrollViewBottomInset()
}
@@ -153,8 +150,8 @@ UICollectionViewDelegateFlowLayout, UICollectionViewDataSource {
private func setupDefaults() {
extendedLayoutIncludesOpaqueBars = true
- automaticallyAdjustsScrollViewInsets = false
view.backgroundColor = .backgroundColor
+ messagesCollectionView.contentInsetAdjustmentBehavior = .never
messagesCollectionView.keyboardDismissMode = .interactive
messagesCollectionView.alwaysBounceVertical = true
messagesCollectionView.backgroundColor = .backgroundColor
@@ -172,17 +169,11 @@ UICollectionViewDelegateFlowLayout, UICollectionViewDataSource {
private func setupConstraints() {
messagesCollectionView.translatesAutoresizingMaskIntoConstraints = false
- let top = messagesCollectionView.topAnchor.constraint(equalTo: view.topAnchor, constant: topLayoutGuide.length)
+ let top = messagesCollectionView.topAnchor.constraint(equalTo: view.safeAreaLayoutGuide.topAnchor)
let bottom = messagesCollectionView.bottomAnchor.constraint(equalTo: view.bottomAnchor)
- if #available(iOS 11.0, *) {
- let leading = messagesCollectionView.leadingAnchor.constraint(equalTo: view.safeAreaLayoutGuide.leadingAnchor)
- let trailing = messagesCollectionView.trailingAnchor.constraint(equalTo: view.safeAreaLayoutGuide.trailingAnchor)
- NSLayoutConstraint.activate([top, bottom, trailing, leading])
- } else {
- let leading = messagesCollectionView.leadingAnchor.constraint(equalTo: view.leadingAnchor)
- let trailing = messagesCollectionView.trailingAnchor.constraint(equalTo: view.trailingAnchor)
- NSLayoutConstraint.activate([top, bottom, trailing, leading])
- }
+ let leading = messagesCollectionView.leadingAnchor.constraint(equalTo: view.safeAreaLayoutGuide.leadingAnchor)
+ let trailing = messagesCollectionView.trailingAnchor.constraint(equalTo: view.safeAreaLayoutGuide.trailingAnchor)
+ NSLayoutConstraint.activate([top, bottom, trailing, leading])
}
// MARK: - Typing Indicator API
From 26c38d512a5e265be6d31c9f5ee70966bcf5e232 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 15:17:23 +0100
Subject: [PATCH 04/12] Update example project
---
Example/ChatExample.xcodeproj/project.pbxproj | 4 +--
.../xcschemes/ChatExample.xcscheme | 28 ++++++++-----------
.../xcschemes/ChatExampleUITests.xcscheme | 6 +---
Example/Podfile | 2 +-
Example/Podfile.lock | 8 +++---
.../LaunchViewController.swift | 8 ++----
.../NavigationController.swift | 12 ++------
.../MessagesViewController+Keyboard.swift | 2 +-
8 files changed, 26 insertions(+), 44 deletions(-)
diff --git a/Example/ChatExample.xcodeproj/project.pbxproj b/Example/ChatExample.xcodeproj/project.pbxproj
index 89a85340..e7a86915 100644
--- a/Example/ChatExample.xcodeproj/project.pbxproj
+++ b/Example/ChatExample.xcodeproj/project.pbxproj
@@ -647,7 +647,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -699,7 +699,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_VERSION = 5.0;
diff --git a/Example/ChatExample.xcodeproj/xcshareddata/xcschemes/ChatExample.xcscheme b/Example/ChatExample.xcodeproj/xcshareddata/xcschemes/ChatExample.xcscheme
index 31f17b89..fec5e125 100644
--- a/Example/ChatExample.xcodeproj/xcshareddata/xcschemes/ChatExample.xcscheme
+++ b/Example/ChatExample.xcodeproj/xcshareddata/xcschemes/ChatExample.xcscheme
@@ -1,6 +1,6 @@
+ shouldUseLaunchSchemeArgsEnv = "YES"
+ codeCoverageEnabled = "YES">
+
+
+
+
@@ -54,17 +63,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
4.3.0)
DEPENDENCIES:
@@ -18,8 +18,8 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
InputBarAccessoryView: 58a348be7ea2736c7eec60e5c315511c2dbb39fd
- MessageKit: 6b809a162328346e0727dbcd040b5f9fd5f5ba15
+ MessageKit: 3c593dc22f7465f74822e4a873ef3157a3e05080
-PODFILE CHECKSUM: 90bd12ca685503630d7fe716609f4974660ed5ee
+PODFILE CHECKSUM: 4b1c4ce3f56911e047bb185e2994398be7f67d2a
-COCOAPODS: 1.8.4
+COCOAPODS: 1.9.0
diff --git a/Example/Sources/View Controllers/LaunchViewController.swift b/Example/Sources/View Controllers/LaunchViewController.swift
index 50794115..d4b49550 100644
--- a/Example/Sources/View Controllers/LaunchViewController.swift
+++ b/Example/Sources/View Controllers/LaunchViewController.swift
@@ -46,16 +46,12 @@ final internal class LaunchViewController: UITableViewController {
override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
- if #available(iOS 11.0, *) {
- navigationController?.navigationBar.prefersLargeTitles = true
- }
+ navigationController?.navigationBar.prefersLargeTitles = true
}
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
- if #available(iOS 11.0, *) {
- navigationController?.navigationBar.prefersLargeTitles = false
- }
+ navigationController?.navigationBar.prefersLargeTitles = false
}
// MARK: - UITableViewDataSource
diff --git a/Example/Sources/View Controllers/NavigationController.swift b/Example/Sources/View Controllers/NavigationController.swift
index cc2d7eb2..c47cace5 100644
--- a/Example/Sources/View Controllers/NavigationController.swift
+++ b/Example/Sources/View Controllers/NavigationController.swift
@@ -36,9 +36,7 @@ final class NavigationController: UINavigationController {
navigationBar.tintColor = .white
navigationBar.barTintColor = .primaryColor
navigationBar.titleTextAttributes = [.foregroundColor: UIColor.white]
- if #available(iOS 11.0, *) {
- navigationBar.largeTitleTextAttributes = [.foregroundColor: UIColor.white]
- }
+ navigationBar.largeTitleTextAttributes = [.foregroundColor: UIColor.white]
navigationBar.shadowImage = UIImage()
navigationBar.setBackgroundImage(UIImage(), for: .default)
view.backgroundColor = .primaryColor
@@ -50,17 +48,13 @@ final class NavigationController: UINavigationController {
navigationBar.barTintColor = .primaryColor
navigationBar.tintColor = .white
navigationBar.titleTextAttributes = [.foregroundColor: UIColor.white]
- if #available(iOS 11.0, *) {
- navigationBar.largeTitleTextAttributes = [.foregroundColor: UIColor.white]
- }
+ navigationBar.largeTitleTextAttributes = [.foregroundColor: UIColor.white]
} else if style == .lightContent {
navigationBar.shadowImage = nil
navigationBar.barTintColor = .white
navigationBar.tintColor = UIColor(red: 0, green: 0.5, blue: 1, alpha: 1)
navigationBar.titleTextAttributes = [.foregroundColor: UIColor.black]
- if #available(iOS 11.0, *) {
- navigationBar.largeTitleTextAttributes = [.foregroundColor: UIColor.black]
- }
+ navigationBar.largeTitleTextAttributes = [.foregroundColor: UIColor.black]
}
}
diff --git a/Sources/Controllers/MessagesViewController+Keyboard.swift b/Sources/Controllers/MessagesViewController+Keyboard.swift
index 223c3efe..816a9ad1 100644
--- a/Sources/Controllers/MessagesViewController+Keyboard.swift
+++ b/Sources/Controllers/MessagesViewController+Keyboard.swift
@@ -123,7 +123,7 @@ internal extension MessagesViewController {
return max(0, inputAccessoryViewHeight + additionalBottomInset - automaticallyAddedBottomInset)
}
- /// iOS 11's UIScrollView can automatically add safe area insets to its contentInset,
+ /// UIScrollView can automatically add safe area insets to its contentInset,
/// which needs to be accounted for when setting the contentInset based on screen coordinates.
///
/// - Returns: The distance automatically added to contentInset.bottom, if any.
From c57db5f4b2188b434b95f7c9afdeddc995953330 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 15:19:24 +0100
Subject: [PATCH 05/12] Update changelog
---
CHANGELOG.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index de8c4447..98ec6126 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -10,6 +10,8 @@ The changelog for `MessageKit`. Also see the [releases](https://github.com/Messa
### Changed
+- **Breaking Change** Dropped support for iOS 9 and iOS 10 [#1261](https://github.com/MessageKit/MessageKit/pull/1261) by [@kaspik](https://github.com/kaspik)
+
## 3.1.0
### Fixed
From e20dcc44925872531f8f8775aed23f9dda2419e7 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 15:25:19 +0100
Subject: [PATCH 06/12] Remove travis.ci file as this project uses Circle CI
---
.travis.yml | 53 -----------------------------------------------------
1 file changed, 53 deletions(-)
delete mode 100644 .travis.yml
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index 8b89d351..00000000
--- a/.travis.yml
+++ /dev/null
@@ -1,53 +0,0 @@
-language: objective-c
-osx_image: xcode8.1
-
-env:
- global:
- - LANG=en_US.UTF-8
-
- - PROJECT="MessageKit.xcodeproj"
- - IOS_SCHEME="MessageKit"
- - IOS_SDK=iphonesimulator10.1
-
- matrix:
-
- - DESTINATION="OS=9.0,name=iPhone 6 Plus" SDK="$IOS_SDK" SCHEME="$IOS_SCHEME" RUN_TESTS="YES" BUILD_EXAMPLE="YES" POD_LINT="NO" RUN_UI_TESTS="YES"
- - DESTINATION="OS=9.1,name=iPhone 6s" SDK="$IOS_SDK" SCHEME="$IOS_SCHEME" RUN_TESTS="YES" BUILD_EXAMPLE="NO" POD_LINT="NO" RUN_UI_TESTS="NO"
- - DESTINATION="OS=9.2,name=iPhone 6s" SDK="$IOS_SDK" SCHEME="$IOS_SCHEME" RUN_TESTS="YES" BUILD_EXAMPLE="NO" POD_LINT="NO" RUN_UI_TESTS="NO"
- - DESTINATION="OS=9.3,name=iPad Pro" SDK="$IOS_SDK" SCHEME="$IOS_SCHEME" RUN_TESTS="YES" BUILD_EXAMPLE="NO" POD_LINT="NO" RUN_UI_TESTS="NO"
-
- - DESTINATION="OS=10.0,name=iPhone 6s" SDK="$IOS_SDK" SCHEME="$IOS_SCHEME" RUN_TESTS="YES" BUILD_EXAMPLE="YES" POD_LINT="NO" RUN_UI_TESTS="YES"
- - DESTINATION="OS=10.1,name=iPhone 7" SDK="$IOS_SDK" SCHEME="$IOS_SCHEME" RUN_TESTS="YES" BUILD_EXAMPLE="NO" POD_LINT="NO" RUN_UI_TESTS="NO"
-
-script:
-
-- if [ $POD_LINT == "YES" ]; then
- pod lib lint;
- fi
-
-
-- if [ $BUILD_EXAMPLE == "YES" ]; then
- xcodebuild build analyze -project Example/ChatExample.xcodeproj -scheme ChatExample -sdk "$SDK" -destination "$DESTINATION" ONLY_ACTIVE_ARCH=NO CODE_SIGNING_REQUIRED=NO | xcpretty -c;
- fi
-
-
-- if [ $RUN_TESTS == "YES" ]; then
- xcodebuild analyze test -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO CODE_SIGNING_REQUIRED=NO | xcpretty -c;
- else
- xcodebuild build analyze -project "$PROJECT" -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO CODE_SIGNING_REQUIRED=NO | xcpretty -c;
- fi
-
-
-- if [ $RUN_UI_TESTS == "YES" ]; then
- xcodebuild test -project Example/ChatExample.xcodeproj -scheme ChatExampleUITests -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO | xcpretty -c;
- fi
-
-
-# Build for reporting test coverage
-- if [ $RUN_TESTS == "YES" ]; then
- xcodebuild test -project MessageKit.xcodeproj -scheme MessageKit -destination "platform=iOS Simulator,name=iPhone 7" CODE_SIGNING_REQUIRED=NO;
- fi
-
-
-after_success:
-- bash <(curl -s https://codecov.io/bash)
From 9a492e916a689b660668e051195da5d3d02ca4f3 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 15:39:28 +0100
Subject: [PATCH 07/12] Fix tests
---
Tests/ControllersTest/MessagesViewControllerSpec.swift | 3 ---
1 file changed, 3 deletions(-)
diff --git a/Tests/ControllersTest/MessagesViewControllerSpec.swift b/Tests/ControllersTest/MessagesViewControllerSpec.swift
index 5717fb32..e33d4a76 100644
--- a/Tests/ControllersTest/MessagesViewControllerSpec.swift
+++ b/Tests/ControllersTest/MessagesViewControllerSpec.swift
@@ -63,9 +63,6 @@ final class MessagesViewControllerSpec: QuickSpec {
beforeEach {
controller.view.layoutIfNeeded()
}
- it("sets automaticallyAdjustsScrollViewInsets to false") {
- expect(controller.automaticallyAdjustsScrollViewInsets).to(beFalse())
- }
it("sets extendedLayoutIncludesOpaqueBars to true") {
expect(controller.extendedLayoutIncludesOpaqueBars).to(beTrue())
}
From 46616a05e1beadd6c343890c2a3b68dbd94528fe Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 21:05:12 +0100
Subject: [PATCH 08/12] Update codecov code
---
.codecov.yml | 32 --------------------------------
codecov.yml | 16 ++++++++++++++++
2 files changed, 16 insertions(+), 32 deletions(-)
delete mode 100644 .codecov.yml
create mode 100644 codecov.yml
diff --git a/.codecov.yml b/.codecov.yml
deleted file mode 100644
index 18f175cb..00000000
--- a/.codecov.yml
+++ /dev/null
@@ -1,32 +0,0 @@
-codecov:
- branch: develop
-
-coverage:
- precision: 2
- round: nearest
- range: "60...100"
- ignore:
- - Tests/*
-
-status:
- project:
- default:
- target: auto
- threshold: 2.0
- branches:
- - master
- - develop
-
- patch:
- default:
- target: auto
- branches:
- - master
- - develop
-
-comment:
- layout: "header, diff, changes, sunburst, uncovered"
- branches:
- - master
- - develop
- behavior: default
diff --git a/codecov.yml b/codecov.yml
new file mode 100644
index 00000000..e816b1e2
--- /dev/null
+++ b/codecov.yml
@@ -0,0 +1,16 @@
+codecov:
+ require_ci_to_pass: true
+
+coverage:
+ precision: 2
+ round: nearest
+ range: "40...100"
+ ignore:
+ - Tests/*
+
+comment:
+ layout: "header, diff, changes, sunburst, uncovered"
+ branches:
+ - master
+ - development
+ behavior: default
From b0ab6f99e36bc4d4be64e59ccd41a7648993c25a Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Fri, 28 Feb 2020 21:06:23 +0100
Subject: [PATCH 09/12] Fix badge for correct branch
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 75c8a413..ed2ea152 100644
--- a/README.md
+++ b/README.md
@@ -5,7 +5,7 @@
[](https://circleci.com/gh/MessageKit/MessageKit)
-[](https://codecov.io/gh/MessageKit/MessageKit)
+[](https://codecov.io/gh/MessageKit/MessageKit)
[](https://github.com/Carthage/Carthage)
From ce54a3ba7e2ca23e6eca21da43a5fe5541f27b11 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Tue, 10 Mar 2020 02:07:50 +0100
Subject: [PATCH 10/12] Revert "Update codecov code"
This reverts commit 46616a05e1beadd6c343890c2a3b68dbd94528fe.
---
.codecov.yml | 32 ++++++++++++++++++++++++++++++++
codecov.yml | 16 ----------------
2 files changed, 32 insertions(+), 16 deletions(-)
create mode 100644 .codecov.yml
delete mode 100644 codecov.yml
diff --git a/.codecov.yml b/.codecov.yml
new file mode 100644
index 00000000..18f175cb
--- /dev/null
+++ b/.codecov.yml
@@ -0,0 +1,32 @@
+codecov:
+ branch: develop
+
+coverage:
+ precision: 2
+ round: nearest
+ range: "60...100"
+ ignore:
+ - Tests/*
+
+status:
+ project:
+ default:
+ target: auto
+ threshold: 2.0
+ branches:
+ - master
+ - develop
+
+ patch:
+ default:
+ target: auto
+ branches:
+ - master
+ - develop
+
+comment:
+ layout: "header, diff, changes, sunburst, uncovered"
+ branches:
+ - master
+ - develop
+ behavior: default
diff --git a/codecov.yml b/codecov.yml
deleted file mode 100644
index e816b1e2..00000000
--- a/codecov.yml
+++ /dev/null
@@ -1,16 +0,0 @@
-codecov:
- require_ci_to_pass: true
-
-coverage:
- precision: 2
- round: nearest
- range: "40...100"
- ignore:
- - Tests/*
-
-comment:
- layout: "header, diff, changes, sunburst, uncovered"
- branches:
- - master
- - development
- behavior: default
From 42d32abf3a1fe2bf57602c87c9e23ffdedabf6b1 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Thu, 19 Mar 2020 20:02:22 +0100
Subject: [PATCH 11/12] Update project and example
---
Example/Sources/View Controllers/LaunchViewController.swift | 4 +---
Example/UITests/ChatExampleUITests.swift | 6 +-----
2 files changed, 2 insertions(+), 8 deletions(-)
diff --git a/Example/Sources/View Controllers/LaunchViewController.swift b/Example/Sources/View Controllers/LaunchViewController.swift
index d4b49550..fc25609b 100644
--- a/Example/Sources/View Controllers/LaunchViewController.swift
+++ b/Example/Sources/View Controllers/LaunchViewController.swift
@@ -96,9 +96,7 @@ final internal class LaunchViewController: UITableViewController {
func openURL(_ url: URL) {
let webViewController = SFSafariViewController(url: url)
- if #available(iOS 10.0, *) {
- webViewController.preferredControlTintColor = .primaryColor
- }
+ webViewController.preferredControlTintColor = .primaryColor
present(webViewController, animated: true, completion: nil)
}
}
diff --git a/Example/UITests/ChatExampleUITests.swift b/Example/UITests/ChatExampleUITests.swift
index d9548ce9..df4df727 100644
--- a/Example/UITests/ChatExampleUITests.swift
+++ b/Example/UITests/ChatExampleUITests.swift
@@ -28,11 +28,7 @@ final class ChatExampleUITests: XCTestCase {
continueAfterFailure = false
// UI tests must launch the application that they test.
// Doing this in setup will make sure it happens for each test method.
- if #available(iOS 9.0, *) {
- XCUIApplication().launch()
- } else {
- // Fallback on earlier versions
- }
+ XCUIApplication().launch()
// In UI tests it’s important to set the initial state
// - such as interface orientation - required for your tests before they run.
From d3f722d81ebd7f0c32da908fdf94130be7d96be5 Mon Sep 17 00:00:00 2001
From: Jakub Kaspar
Date: Thu, 19 Mar 2020 20:16:27 +0100
Subject: [PATCH 12/12] fix cache
---
.github/workflows/ci_pr_example.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/workflows/ci_pr_example.yml b/.github/workflows/ci_pr_example.yml
index 8ab262a5..dbeb0922 100644
--- a/.github/workflows/ci_pr_example.yml
+++ b/.github/workflows/ci_pr_example.yml
@@ -12,7 +12,7 @@ jobs:
- name: Cache Pods
uses: actions/cache@v1
with:
- path: Pods
+ path: Example/Pods
key: ${{ runner.os }}-pods-${{ hashFiles('**/Example/Podfile.lock') }}
restore-keys: |
${{ runner.os }}-pods-