Commit Graph
78 Commits
Author SHA1 Message Date
Chen Liang 67de928005 move database operation off main thread (#4053) 2019-10-28 12:45:47 -07:00
Ryan Wilson 56b37d2543 Fix container instantiation timing, IID startup. (#4030)
* Fix container instantiation timing, IID startup.

The container instantiation could happen at the wrong time, before all
components have been added to the container. This fixes it, and also
moves IID to use the proper instantiation timing instead of relying on
the `configureWithApp:` call. This is part continuation of #3147, where
I'll be fixing the rest of the SDKs in follow up PRs.

* Typo

* Further work on instantiation timing.

This moves the instantiation of components to after the FirebaseApp is
completely configured and assigned, as it should be. This also exposed
a recursive issue with IID calling the Messaging singleton, which in
turn called IID and instantiated multiple instances.

A change was made to break the cycle: the Messaging `isAutoInitEnabled`
call was changed to a static method vs an instance method, allowing IID
to call it during initialization without instantiating the Messaging
instance (since it doesn't have a direct dependency on it).

* Revert unintentional formatting of entire FIRMessaging file.

* Fix tests.

* Format InstanceID.m

* Remove unused import.

* Fix ComponentContainer test.

* Minor PR feedback.
2019-10-11 17:20:46 -04:00
Chen Liang 28038e55aa Remove the class FIRMessagingRmq2PersistentStore (#4045) 2019-10-10 16:11:49 -07:00
Chen Liang b6ac437faa Remove migration logic from document folder to application folder (#4033) 2019-10-10 08:49:42 -07:00
Paul Beusterien 59db09740c Mute FCM deprecated warnings with Xcode 11 and min iOS >= 10 (#3857) 2019-09-16 10:55:20 -07:00
Chen Liang 51ded3fefb should not persist context message ID in loggedMessageIDs (#3670) 2019-08-26 11:13:50 -07:00
Ryan Wilson 615c20cf17 Ensure Messaging instance is usable after FIRApp's delete (#3579)
* Ensure Messaging instance is usable after FIRApp's `delete`

This fixes #3411. Test fails before the code change, and succeeds
afterwards.

* Update CHANGELOG.md

* Use Bug number instead of PR number
2019-08-14 15:06:22 -04:00
Paul Beusterien dbd960db22 Add interop API to prepare for RC open sourcing (#3582) 2019-08-13 18:23:59 -07:00
Chen Liang eade6bd374 kill debug assert and unnecessary macros (#3556) 2019-08-13 14:11:59 -07:00
Chen Liang f090a3cb80 remove internalHeader folder whose file is only used in unit test (#3537) 2019-08-08 13:00:47 -07:00
Chen Liang 5f0118d61f Update all the header path to pod repo relative (#3527)
* update all the path to pod repo relative

* fix a few missed out headers

* reorder the headers
2019-08-08 09:50:35 -07:00
Chen Liang 564e33834d use repo-root relative path for unit test files (#3515) 2019-08-07 17:00:01 -07:00
Chen Liang 5c26ae4e01 Always call getToken before subscription/unsubscription (#3438) 2019-07-30 13:59:29 -07:00
Paul Beusterien 55463b1551 Update to latest version of FirebaseAnalyticsInterop (#3463) 2019-07-29 16:39:29 -07:00
Chen Liang 7eb1747e4b Adding macOS support for Messaging and InstanceID (#2880) 2019-05-30 15:31:38 -07:00
Paul Beusterien 06d36108d8 Add test_spec for FCM (#3088)
* Add test_spec for FCM
* FIRMessagingRemoteNotificationsProxyTest - don't use OCMPartialMock([UIApplication sharedApplication]) to avoid crashing tests on iOS 8 (#3094)
2019-05-28 11:36:31 -07:00
Chen Liang c59c5d62d7 remove FIRMessagingRegistrar class (#2853) 2019-04-17 14:56:16 -07:00
Maksym Malyhin 76aa880853 GULAppDelegateSwizzler - proxy APNS methods separately (#2835) 2019-04-17 17:35:14 -04:00
Chen Liang 8540c21864 Remove reflection call to get checkin info from InstanceID (#2825) 2019-04-16 13:10:08 -07:00
Chen Liang ec2399683b Remove useMessagingDelegateForDirectChannel property (#2711) 2019-04-04 09:46:29 -07:00
Maksym Malyhin 267e9a6ece FIRMessagingRemoteNotificationsProxy updated to use GULAppDelegateSwizzler (#2683) 2019-04-04 09:26:12 -04:00
Chen Liang 98549593ac fix a few place that copybara not properly handle the change (#2678) 2019-03-29 12:23:43 -07:00
Chen Liang e024df5073 fix typo in iOS target (#2673)
* also a few minor cleanup
2019-03-28 16:13:20 -07:00
Maksym Malyhin 04561fe74d FIRMessagingRemoteNotificationsProxy - test only public API with no assumptions on implementation (#2672) 2019-03-28 19:06:04 -04:00
Chen Liang 0091515b98 add image on notification support (#2644) 2019-03-26 20:15:34 -07:00
Chen Liang d87b15fa69 fix analyze warning in fcm (#2650) 2019-03-26 16:25:46 -07:00
Paul Beusterien 714bb34bc3 Revert #2491 (#2582) 2019-03-18 16:28:18 -07:00
Chen Liang 8061301cb9 File directory for tvOS should change from NSApplicationSupportDirector to NSCachesDirectory (#2496) 2019-03-13 08:57:47 -07:00
Chen Liang 681a5740b0 Add image on notification support (#2491)
This is official image notification support for FCM. Now an image can be rendered in notification when user enable service extension and calling the extensionHelper API.
2019-03-11 14:36:40 -07:00
Chen Liang 00168257df Make FCM and InstanceID compatible with tvOS (#2428) 2019-03-05 11:57:10 -08:00
Maksym Malyhin 8ffd9590cb FirebaseMessaging: NSUserDefaults replaced by GULUserDefaults (#2443)
* FirebaseMessaging: `NSUserDefaults` replaced by `GULUserDefaults`

* FirebaseMessaging: `GoogleUtilities/UserDefaults` added to dependencies. `GoogleUtilities` dependencies version updated to `~> 5.3`

* FIRMessagingPubSub: imports order
2019-02-26 15:31:18 -05:00
Ryan Wilson 1b777acdca Fix IID singleton usage. (#2446)
The singleton is cached and vended from the Core component system, we
shouldn't wrap it in a dispatch_async or cache it with a global variable.

This matches a change internally that has been made and shipped.
2019-02-26 12:26:42 -08:00
Paul Beusterien 82fd4b9fc6 Fix race causing occasional flake (#2427) 2019-02-22 14:36:29 -08:00
Paul Beusterien d232d1c30c Restore FIRInstanceIDWithFCMTest.m (#2417) 2019-02-21 20:16:45 -08:00
Paul Beusterien 6df99be073 Bump FirebaseAnalyticsInterop version (#2315) 2019-02-04 08:23:10 -08:00
Ryan Wilson 5982981e12 Prevent Messaging and IID singleton usage during tests. (#2250)
* Prevent Messaging and IID singleton usage during tests.

* Remove other uses of static Messaging instance.

* Removed usages of messagingForTests.

* Remove unused imports, unify testing code.

* Use local import path instead of framework import.
2019-01-28 18:05:16 -05:00
Chen Liang ab962ce244 use instanceIDForTest for instance init in unit tests (#2239)
* use instanceIDForTest for instance init in unit tests
* looks like realInstanceID is not needed
* Get InstanceID from SpecsStaging to fix tests
2019-01-10 10:49:43 -08:00
Chen Liang bc0329f48d fix the unit test #1451 (#2187) 2018-12-17 10:50:20 -08:00
Paul Beusterien c27db6d477 Fix analyze errors (#2047) 2018-11-05 13:07:22 -08:00
Paul Beusterien ea076e38a6 Don't rely on test always being in foreground (#2021) 2018-10-29 13:15:20 -07:00
Raman Yankouski 86be7764c9 Always use 24-hours locale (#1947)
* Always use 24-hours locale
* use en_US_POSIX instead of en_GB
* Update NSDateFormatter locale for messaging tests
2018-10-16 12:14:24 -07:00
Paul Beusterien 81fb6a03ef Remove need for [FIRApp configure] in Messaging unit tests (#1927)
* Remove need for [FIRApp configure] in Messaging unit tests
* Add missing file to test target
2018-10-10 15:24:04 -07:00
Paul Beusterien 467354a58f Do Messaging's Analytics logging via Interop (#1902) 2018-10-09 16:34:06 -07:00
Chen Liang 845a25e65b Fix the issue that when topic is invalid, the callback was not triggered. (#1880) 2018-09-28 10:27:05 -07:00
Chen Liang 4736e056ef Add a boolean value on whether to use direct channel callback for all ios versions (#1875) 2018-09-26 13:16:07 -07:00
Chen Liang be235ce752 remove unused method (#1682) 2018-08-13 15:04:59 -07:00
Ryan Wilson 1d484d33a7 Rename global data collection switch. (#1560) 2018-07-23 10:34:16 -07:00
Paul Beusterien 98b6eef71e Split GoogleUtilities from FirebaseCore (#1370) 2018-07-06 09:37:23 -07:00
Chen Liang 5e1472b492 Fix the race condition of global data flag and fcm auto init enabled flag (#1466) 2018-06-29 11:39:45 -07:00
Paul Beusterien 6eb22aa3a0 Disable failing didReceiveRemoteNotification tests(#1451) (#1452) 2018-06-25 17:16:20 -07:00