Commit Graph
32 Commits
Author SHA1 Message Date
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
Chen Liang 468cb91517 add a warning message that the topic operation is suspended without a token (#1427) 2018-06-19 15:59:04 -07:00
Chen Liang 69ccd6d8b1 Corrected the deprecation warning when subscribing to or unsubscribing from a topic (#1425) 2018-06-19 14:08:53 -07:00
Ryan Wilson 08f447cd3f Add global data collection switch. (#1219)
* Addition of global data collection switch.
* Added Messaging conformance to data switch.
  Also formatted code.
* Move data collection flag internal until all SDKs conform to it.
* Formatting in response to code review.
2018-05-14 10:02:25 -07:00
Chen Liang 58b0aefc66 replace the private OCMock method with a public one, and also fix the EXC_BAD_ACCESSw (#1149) 2018-04-19 17:03:45 -07:00
Chen Liang 609cd0328a Options should be nullable for subscription (#1085)
Getting warning message from xcode so we need to define it to remove warning.
2018-04-13 11:15:28 -07:00
Paul Beusterien 42bc113754 Travis static library testing (#1047)
* Add Objective C example app for Messaging
* Travis static library testing
* static lib build fixes
2018-04-09 09:11:21 -07:00
Chen Liang 653aea7b50 Adding a new topic subscription/unsubcription with completion handler method (#1001)
* add new topic subscription/unsubscription method with handler
2018-03-30 11:41:38 -07:00
Ben Hamilton (Ben Gertzfield) cb1f65dfcf Migrate Firebase off ObjC module @import statements (#992)
* Migrate Firebase off @import statements

* - Migrate tests and test utils from @import to #import.
  - Update Xcode projects for tests to explicitly link in framework deps.
  - Update check_no_module_imports.sh to look for @imports in tests/test utils/
    integration tests.

* Ensure check_no_module_imports.sh explicitly exits with code 0 on success.
2018-03-29 08:44:48 -07:00
Morgan Chen c67031386d Remove FIRMessagingInstanceIDProxy 2018-03-27 12:37:27 -07:00
Chen Liang 976635fd87 avoid using initWithSuiteName which does not support iOS 7 (#765) 2018-02-06 18:13:54 -08:00
Oleksiy Ivanov 4e4c82b659 Fix tests. 2018-01-31 09:47:18 -08:00
Chen Liang 5306474396 adding unit test for auto init enable function (#710) 2018-01-25 13:44:22 -08:00
davidair a84704f65b Removing an obsolete setting from plist files (#617)
* Removing an obsolete setting from plist files

* Fixing Unit Tests

* Fixing nullability
2018-01-08 10:41:25 -05:00
Paul Beusterien da9308408d Use brackets for module imports (#487) 2017-11-22 09:19:10 -08:00
Paul Beusterien 3e592526ec Buildable and interoperable source pods (#444) 2017-11-21 17:02:22 -08:00
Paul Beusterien cfd8118355 Update messaging test for upcoming InstanceID changes (#425) 2017-11-03 12:28:03 -07:00
Riz 2b40693be4 Add simpler delegate method for FCM tokens (#375)
This new delegate method will be called generally once per app start, to always provide a current token. This token may change over time. This simpler method makes integration much simpler, as:

* Developers no longer have to check for a current token using the `.fcmToken` property, and also check for token changes using the `-messaging:didRefreshRegistrationToken:` delegate method.
* There is a single code path for when a token is available, making operations that depend on a token being available easier to implement. For example, this is the right method to always upload your FCM token to your application server, or to subscribe to topics, etc.
2017-10-12 16:09:07 -07:00
Riz 5496eff88f Don't swizzle missing and optional delegate methods
FCM's swizzling of the user notification center currently swizzles only one of the two optional delegate methods (userNotificationCenter:willPresentNotification:withCompletionHandler:), but not the other (userNotificationCenter:didReceiveNotificationResponse:withCompletionHandler:).

The didReceiveNotificationResponse, if implemented by the delegate, is the sole receiver of all user action on a notification, including simply tapping on the notification itself. Prior to this change, if the developer had implemented didReceiveNotificationResponse, then FCM would not be able to collect this event for analytics.

Additionally, I changed the logic in FIRMessagingRemoteNotificationsProxy to check whether these methods are actually implemented before swizzling them. It was always swizzling, which meant it was adding an implementation if the method didn't exist. This would confuse iOS into thinking the developer did implement these methods and NOT fall back to delivering the notifications to the application delegate.

With this change, if the developer did not implement these methods, then FCM will not swizzle those methods. That keeps the behavior true to what the developer intended.
2017-10-04 18:39:30 -07:00
Paul Beusterien 3b6762135a Fix trailing space travis failure (#294) 2017-09-20 14:14:39 -07:00
Riz 637bf879ad Log incoming notifications to console as JSON (#286)
This will help debug incoming notifications.
2017-09-19 14:28:06 -07:00
Riz 66f3aeda16 Log direct-channel state changes to console (#287) 2017-09-19 12:58:58 -07:00
Riz 446c5c0267 Remove FIRMessaging_FAIL macro, log result code (#265)
This removes the `FIRMessaging_FAIL` macro which was using `__builtin_trap()`, and replaced with `NSAssert` calls. These `NSAssert` calls may not get called in release builds, and so we also log them with FIRLogger error messages.

The RMQ database open error result code is now parsed and included in the error message to help us identify causes for #199 .
2017-09-13 17:43:17 -07:00
Paul Beusterien 053b2f11ea Use modulemap to fix exposure of FirebaseCore's internal headers (#121) 2017-07-10 14:57:03 -07:00
Paul Beusterien 0297375121 Rename FirebaseDev to FirebaseCommunity (#98) 2017-06-22 13:08:35 -07:00
Mathew Huusko V 5c59342e6e macOS (#38)
* Example/Core: create macOS app/tests target

* Example/Core: Core_Example/Tests -> Core_Example/Tests_iOS

* Example/Core: macOS building/tests passing

* Example/Database: separate iOS/macOS targets

* BuildFrameworks: macOS

* .travis.yml, test.sh: AllUnitTests -> AllUnitTests_iOS

* test.sh: add AllUnitTests_macOS

* Example/Storage: Example/Tests->_iOS

* Example/Storage: macOS

* test.sh: try to prevent double error 65

* test.sh: build before test

* Example/Auth|Messaging: -> _iOS

* Example/Auth: macOS build

* Example/Auth: macOS passing

* Example/Firebase: pod de/re-integrate; fix static DerivedData references; copy phase for OCMock

* Example/Firebase: manually copied OCMock, Products Dir vs. Frameworks

* Example/Firebase: copied OCMock, prevent header removal

* Example/Storage: integration tests sdk fix

* Example/Auth: macOS exclude FIRAuthAppCredentialManager; cleanup

* Firebase/Core: remove nullability annotation

* Firebase/Core|Database: correct TARGET_X usage for correctness and anticipation of OS_WATCH|TV branches

* build.swift: style fix

* Firebase/Core: FIRLogger: fix macOS intermittent va_list error
2017-06-02 10:42:17 -07:00
Riz 2c133b34b0 Clean up logging and configuration in Messaging (#28)
* Remove mostly unused code from FIRMessagingLogger

This cleans up some left-over old logging logic from before we moved to FIRLogger in Firebase Core. We no longer need this logging functionality.

* Delete FIRMessagingConfig.{h,m}

We no longer need a config class to store an unused log level filter (that filter is no longer needed).
2017-05-24 17:29:09 -07:00
Riz ed1b609852 Enable direct channel in the sample app (#7)
This shows the simple property, shouldEstablishDirectChannel, to open a new channel, and how to show incoming messages with the iOS 10 delegate handler
2017-05-19 10:43:03 -07:00
Paul Beusterien 98ba64449a Initial 2017-05-15 12:27:07 -07:00