Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing error #1

Closed
kination opened this issue Dec 7, 2017 · 2 comments
Closed

Testing error #1

kination opened this issue Dec 7, 2017 · 2 comments

Comments

@kination
Copy link

kination commented Dec 7, 2017

Hello. Thanks for good project.
I'm running test after setup FCM_SERVER_KEY, but it shows error like

1) test payload test (FcmexTest)
     test/fcmex_test.exs:182
     Expected false or nil, got true
     code: refute Map.has_key?(payload, :mutable_content)
     stacktrace:
       test/fcmex_test.exs:184: (test)

.
14:13:22.134 [error] GenServer #PID<0.2279.0> terminating
** (ExVCR.RequestNotMatchError) Request did not match with any one in the current cassette: fixture/vcr_cassettes/over_thousand_messages.json.
Delete the current cassette with [mix vcr.delete] and re-record.

Request: [:post, "https://fcm.googleapis.com/fcm/send", [{"Content-Type", "application/json"}, {"Authorization", "key=my_fcm_server_key"}], "{\"to\":null,\"time_to_live\":null,\"registration_ids\":[\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\",\"FCM_TOKEN\"
...
Finished in 1.5 seconds
10 tests, 2 failures

Do I have to setup registration id, or something else?
Failure happens in test payload test (FcmexTest) and test request 1000+ more messages (FcmexTest).

Thanks.

shufo added a commit that referenced this issue Dec 7, 2017
shufo added a commit that referenced this issue Dec 7, 2017
shufo added a commit that referenced this issue Dec 7, 2017
@shufo
Copy link
Owner

shufo commented Dec 7, 2017

@djKooks
Hi djKooks.
Sorry, I missed update the fixture to latest version.
Now it's fixed on master. please update the source code and try mix test.
https://travis-ci.org/shufo/fcmex/builds/312856886

Also updated package version to 0.1.2.

shufo added a commit that referenced this issue Dec 7, 2017
@kination
Copy link
Author

kination commented Dec 7, 2017

@shufo It works now! Thanks.

@kination kination closed this as completed Dec 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants