Skip to content

Commit

Permalink
internet reader e2e tests
Browse files Browse the repository at this point in the history
internet reader e2e fixes

fix typo

fix e2e tests

tests fixes and improvements

setReadDisplay/clearReaderDisplay e2e test

run setReaderDisplay e2e only on iOS

fix setReaderDisplay test

fix setReaderDisplay scenario

fix test

fix e2e test

improve reader display screen layout

prettier/eslint js files (#172)

* updates

* updates linting settings, adds prettier target

* npm reg

removed tvos target (#179)

templates (#181)

yarn diff check (#180)

* add manual yarn.lock diff check

* force fail

* how about this

* and this

* restore lockfile

Create expo plugin (#113)

* chore: create expo plugin

* chore: add plugin params

* chore: add expo docs

* fix package.json path

upgrade tsc and clean up example app routing param types (#185)

* upgrade tsc

* clean up routing param types

fix: TextInput color on Android (#84)

npm release script (#87)

* chore: add publish script

* chore: update docs

test connection token on init (#177)

* chore: test connection token on init

* chore: render app conditionally

Handle other Android connection methods (#111)

* chore: handle other connection methods

* chore: add proper e2e tests

* fix: e2e tests

* fix: e2e test

* fix indentations

* fix methods params

* fix merge issues

Revert "Handle other Android connection methods (#111)" (#186)

This reverts commit 18db810.

fix dependabot minimist issue (#189)

usb connection type (#188)

upgrade minimist in example app as well (#190)

duplicated event listeners (#182)

* fix: duplicated event listeners

* temporary listener fix

* fix typings

* cleanup

* fix updateing callbacks refs

fix labels

handle multiple secret keys, in-person refund tests

updated android sdk to 2.7.1 (#200)

Android validation and transformation helpers (#192)

* making use of new transformation functions

* validation helpers

* removed some mappers

Handle other Android connection methods #111 (#187)

* chore: handle other connection methods

* chore: add proper e2e tests

* fix: e2e tests

* fix: e2e test

* fix methods params

* rebase fixes

* rebase fix

Co-authored-by: David Henry <dhenry@stripe.com>

StripeTerminalReactNativeModule reduced scope (#202)

* separated callbacks and listeners from RN module

* cancelOperation added

* ReactNativeConstants imports

* extracting reader.serialNumber

[wip] update readme with expo guidance and re-order content (#206)

* update readme with expo guidance and re-order content

* more

* shufflin things

* toc

more doc fixes (#207)

* more fixes

* refactor

* add note about links not being available

adding codeowners (#208)

[WIP] Android unit tests (#204)

* separated callbacks and listeners from RN module

* TokenProvider unit tests

* run unit tests in circleci

* unit test yarn command

* BluetoothReaderListener unit tests

* store test results

* DiscoveryListener unit tests

* updated test output path

* test results path updated

* UsbListenerTest

* TerminalListener and HandoffReaderListener unit tests

* one more try with the test output path

Bump plist from 3.0.4 to 3.0.5 (#216)

Bumps [plist](https://github.com/TooTallNate/node-plist) from 3.0.4 to 3.0.5.
- [Release notes](https://github.com/TooTallNate/node-plist/releases)
- [Changelog](https://github.com/TooTallNate/plist.js/blob/master/History.md)
- [Commits](https://github.com/TooTallNate/node-plist/commits)

---
updated-dependencies:
- dependency-name: plist
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Bump ansi-regex from 4.1.0 to 4.1.1 (#215)

Bumps [ansi-regex](https://github.com/chalk/ansi-regex) from 4.1.0 to 4.1.1.
- [Release notes](https://github.com/chalk/ansi-regex/releases)
- [Commits](chalk/ansi-regex@v4.1.0...v4.1.1)

---
updated-dependencies:
- dependency-name: ansi-regex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Bump ansi-regex from 4.1.0 to 4.1.1 in /example (#213)

Bumps [ansi-regex](https://github.com/chalk/ansi-regex) from 4.1.0 to 4.1.1.
- [Release notes](https://github.com/chalk/ansi-regex/releases)
- [Commits](chalk/ansi-regex@v4.1.0...v4.1.1)

---
updated-dependencies:
- dependency-name: ansi-regex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Bump plist from 3.0.4 to 3.0.5 in /example (#214)

Bumps [plist](https://github.com/TooTallNate/node-plist) from 3.0.4 to 3.0.5.
- [Release notes](https://github.com/TooTallNate/node-plist/releases)
- [Changelog](https://github.com/TooTallNate/plist.js/blob/master/History.md)
- [Commits](https://github.com/TooTallNate/node-plist/commits)

---
updated-dependencies:
- dependency-name: plist
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Reader update errors received by RN SDK (#217)

* reader update errors received by RN SDK

* lint

* ios SDK sends update errors to RN SDK

Prevent from calling methods before SDK initializing SDK (#203)

* prevent from calling methods before SDK initializing SDK

* improve error message

* isInitialized as a util function

Memoize StripeTerminalProvider values (#221)

* fixing hooks deps

* fix android all target

* pushing looping location check

* memoize context

* discover

* rrc

* setupIntents

android permissions util (#218)

* android permissions util

* improve location permission message

add android expo steps to readme (#210)

* add android steps

* shuffle

* update both files

* toc

test tokenProvider on init (#211)

* test tokenProvider on init

* catchable tokenProvider error

Revert "Prevent from calling methods before SDK initializing SDK (#203)" (#225)

This reverts commit 38972ad.

added metadata property to enable Android SDK RN identification (#227)

rename e2e file

patch package

revert API_URL

handle CA server

fix commands

script rename

fix server:ci command

use canada API url from env

fix server endpoint

fix createPaymentIntent via server

Add android expo support and permissions checker (#224)

* update perms helper

* it works

* docs

* refactor permissions utils

logLevel only on StripeTerminalProvider component level (#223)

* logLevel only on StripeTerminalProvider component level

* fix typo

createPaymentIntent uses INTERAC_PRESENT for CAD currency (#232)

* createPaymentIntent uses INTERAC_PRESENT for CAD currency

* createPaymentIntent receives paymentMethodTypes from the POS application

* enum mapping fix

add setSimulatedCard method

clean up

use bluetooth reader for collecting CA payments

fix e2e tests

use keyboard aware scroll view

fix linter

set unique testID

fix tests

fix in-person refund e2e

scroll to bottom before tap

fix log name

fetch latest interac charge

refund - set test card number

fix refund e2e

fix e2e

fix android ui

fix e2e test, record failing tests

prevent call methods being not initialized (#228)

* prevent from calling methods before SDK initializing SDK

* improve error message

* isInitialized as a util function

* improvements

* remove direct functions export

implement onDidReportAvailableUpdate in example app (#236)

enable interac for e2e android scenario

skip refunding tests on android

fix e2e test

add comments
  • Loading branch information
arekkubaczkowski authored and jdivock-stripe committed Apr 6, 2022
1 parent a8e35ae commit 9e02c8a
Show file tree
Hide file tree
Showing 89 changed files with 4,731 additions and 2,260 deletions.
12 changes: 10 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,11 @@ jobs:
- run:
name: Install dependencies
command: |
yarn install --cwd example --frozen-lockfile
yarn install --frozen-lockfile
set -e
yarn install --cwd example
yarn install
echo "Checking for diffs in yarn lockfile, if this fails please ensure all dependencies are up to date"
git diff --exit-code
- save_cache:
key: dependencies-{{ checksum "package.json" }}
paths: [node_modules]
Expand Down Expand Up @@ -251,6 +254,11 @@ jobs:
name: build for detox
- android/save-gradle-cache
- android/save-build-cache
- run:
command: yarn unit-test:android
name: unit tests
- store_test_results:
path: ~/android/build/test-results/testDebugUnitTest
- run:
no_output_timeout: 60m
command: yarn e2e:test:android:release
Expand Down
34 changes: 34 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''
---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:

1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Smartphone (please complete the following information):**

- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]

**Additional context**
Add any other context about the problem here.
19 changes: 19 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''
---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
21 changes: 21 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
## Summary

<!-- Simple summary of what was changed. -->

## Motivation

<!-- Why are you making this change? If it's for fixing a bug, if possible, please include a link to the relevant issue, a code snippet, or an example project that demonstrates the bug. -->

## Testing

<!-- Did you test your changes? Ideally you should check both of the following boxes. -->

- [ ] I tested this manually
- [ ] I added automated tests

## Documentation

Select one:

- [ ] I have added relevant documentation for my changes.
- [ ] This PR does not result in any developer-facing changes.
1 change: 1 addition & 0 deletions CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @jdivock-stripe @dhenry-stripe @jil-stripe @arekkubaczkowski
76 changes: 76 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Contributor Covenant Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to make participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, sex characteristics, gender identity and expression,
level of experience, education, socio-economic status, nationality, personal
appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment
include:

- Using welcoming and inclusive language
- Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
- Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

- The use of sexualized language or imagery and unwelcome sexual attention or
advances
- Trolling, insulting/derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or electronic
address, without explicit permission
- Other conduct which could reasonably be considered inappropriate in a
professional setting

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.

## Scope

This Code of Conduct applies within all project spaces, and it also applies when
an individual is representing the project or its community in public spaces.
Examples of representing a project or community include using an official
project e-mail address, posting via an official social media account, or acting
as an appointed representative at an online or offline event. Representation of
a project may be further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project team at conduct@stripe.com. All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html

[homepage]: https://www.contributor-covenant.org

For answers to common questions about this code of conduct, see
https://www.contributor-covenant.org/faq
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,12 @@ Our pre-commit hooks verify that the linter and tests pass when committing.

### Publishing to npm

We use [release-it](https://github.com/release-it/release-it) to make it easier to publish new versions. It handles common tasks like bumping version based on semver, creating tags and releases etc.
We use a custom script for releasing the library to the NPM. It handles common tasks like bumping version based on semver, creating tags and releases etc.

To publish new versions, run the following:
To publish new versions, run the following command from the root directory:

```sh
yarn release
sh scripts/publish.sh <release_type>
```

### Scripts
Expand Down
Loading

0 comments on commit 9e02c8a

Please sign in to comment.