-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[release note] - [feature-instance] --> sub feature complete "Subscribe"
- Loading branch information
1 parent
5e968cf
commit 7ae812f
Showing
50 changed files
with
993 additions
and
160 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,7 @@ on: | |
push: | ||
paths-ignore: | ||
- '.github/**' | ||
- 'README.md' | ||
branches: [ "dev" ] | ||
|
||
jobs: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,7 @@ on: | |
push: | ||
paths-ignore: | ||
- '.github/**' | ||
- 'README.md' | ||
branches: [ "main" ] | ||
|
||
workflow_dispatch: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,5 @@ local.properties | |
.gradle | ||
build | ||
pusher-notif.txt | ||
*.jks | ||
*.jks | ||
.aiexclude |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,11 @@ | ||
# Update | ||
Rewriting app with clean architecture, acceptance test driven development and continous integration/delivery using Github Actions and Firebase App Distribution. | ||
To access the old version, navigate to this [commit](https://github.com/syedahmedjamil/pushier/commit/ea7f30f8890fba63ff5571d64c3dffbe08dd9bfd) and click "Browse Files". | ||
Updating app using clean architecture, acceptance test driven development and continuous integration/delivery using Github Actions and Firebase App Distribution. To see the old version, navigate to this [commit](https://github.com/syedahmedjamil/pushier/commit/ea7f30f8890fba63ff5571d64c3dffbe08dd9bfd) and click "Browse Files". | ||
|
||
# About | ||
Android client app that integrates with pusher beams to show realtime in-app notifications. | ||
|
||
# Before building the app | ||
1. configure fcm https://pusher.com/docs/beams/getting-started/android/configure-fcm/?ref=docs-index#open-firebase-console | ||
2. make sure when creating app in firebase the **"Android package name"** is same as you set in **build.grade** `applicationId` | ||
3. paste your fcm server key in your pusher beams instance "Settings" page under "Google FCM Integration" field | ||
4. download and store your `google-services.json` file in the app folder | ||
# Tests (new) | ||
![](https://github.com/syedahmedjamil/pushier/blob/main/extras/tests.gif) | ||
|
||
# Payload | ||
> NOTE: your interest name has to be present in the `interests` array as well as in `fcm.data.interest` as shown below for it to work properly. | ||
```json | ||
{ | ||
"interests": [ | ||
"reddit" | ||
], | ||
"fcm": { | ||
"data": { | ||
"interest": "reddit", | ||
"category": "Important", | ||
"date": "1/1/2022", | ||
"title": "How to optimise text size on lower dpi devices", | ||
"body": "In XML, is there any other way than defining new layouts files for different dpi devices just to handle text sizes as it completely messes up the entire layout if not handled properly?", | ||
"subtext": "r/androiddev", | ||
"link": "https://www.reddit.com/r/androiddev/comments/13a3p1c/how_to_optimise_text_size_on_lower_dpi_devices", | ||
"image": "https://media.glassdoor.com/sql/796358/reddit-squarelogo-1490630845152.png" | ||
} | ||
} | ||
} | ||
``` | ||
Sample using curl is located in : https://github.com/syedahmedjamil/pushier/blob/main/extras/payload%20sample%20using%20curl.bat. | ||
|
||
To use this sample you will need `PUSHER-BEAMS-INSTANCE-PRIMARY-KEY` and `PUSHER-BEAMS-INSTANCE-ID` both of which can be found by going to the "Keys" page of your pusher beams instance | ||
|
||
# Demo | ||
# Demo (old) | ||
![](https://github.com/syedahmedjamil/pushier/blob/main/extras/demo.gif) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,5 @@ | |
.gradle | ||
*.jks | ||
*.json | ||
misc | ||
misc | ||
.aiexclude |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
test.properties |
30 changes: 30 additions & 0 deletions
30
app/src/androidTest/assets/features/instance/subscribe.feature
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
Feature: Subscribe | ||
User subscribes to a pusher instance using instance id | ||
|
||
Background: | ||
Given I am on the "Instance" screen | ||
|
||
Scenario: User subscribes with empty instance id | ||
Given I set "" as instance id | ||
When I try to subscribe | ||
Then I should see message "Please enter your Pusher Instance ID." | ||
|
||
Scenario: User subscribes with empty interests | ||
Given I set "00000000-0000-0000-0000-000000000000" as instance id | ||
When I try to subscribe | ||
Then I should see message "Please add at least 1 interest before subscribing." | ||
|
||
Scenario: User subscribes with no internet access | ||
Given Internet connection is turned "off" | ||
And I set "00000000-0000-0000-0000-000000000000" as instance id | ||
And I add "test" as an interest | ||
When I try to subscribe | ||
Then I should see message "Network unavailable." | ||
|
||
Scenario: User subscribes with valid data and internet access | ||
Given Internet connection is turned "on" | ||
And I set "00000000-0000-0000-0000-000000000000" as instance id | ||
And I add "test" as an interest | ||
When I try to subscribe | ||
Then I am on the "Notifications" screen | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.