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

IGAPP-1061: Upgrade react and react native #843

Merged
merged 35 commits into from
Feb 13, 2023
Merged
Show file tree
Hide file tree
Changes from 20 commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
7dffacb
IGAPP-1061: Upgrade react and jest
sarahsporck Dec 7, 2022
85e0147
IGAPP-1061: upgrade react
sarahsporck Feb 1, 2023
0c5f2f3
IGAPP-1061: upgrade react-native
sarahsporck Feb 1, 2023
2e12bff
IGAPP-1061: add form data mock
sarahsporck Feb 1, 2023
a647078
IGAPP-1061: update snapshots due to jest 29
sarahsporck Feb 1, 2023
8b08f6c
IGAPP-1061: Upgrade react and jest
sarahsporck Dec 7, 2022
80485a5
IGAPP-1061: fix type errors and tests
sarahsporck Dec 7, 2022
f088b01
IGAPP-1061: update native app apdroid
sarahsporck Dec 12, 2022
b4b876a
IGAPP-1061: update tests
sarahsporck Jan 17, 2023
d2b8b4c
IGAPP-1061: create licenses in correct assets folder and remove list fix
sarahsporck Jan 25, 2023
6cf4b56
IGAPP-1061: untrack license.json
sarahsporck Jan 25, 2023
f37eff2
IGAPP-1061: Fix merge
steffenkleinle Jan 25, 2023
a6dc6b9
IGAPP-1061: Upgrade RN to 0.70 on iOS
LeandraH Jan 30, 2023
14a9d44
IGAPP-1061: remove unused dependencies
sarahsporck Feb 2, 2023
05f4458
Merge branch 'IGAPP-1061-upgrade-react-and-react-native' into IGAPP-1…
LeandraH Feb 3, 2023
2c4f3aa
Update from main
LeandraH Feb 3, 2023
a62ae94
IGAPP-1061: Upgrade XCode
LeandraH Feb 3, 2023
786ca0f
IGAPP-1061: Fix lint
LeandraH Feb 3, 2023
a733164
IGAPP-1061: Fix Ts Checks
LeandraH Feb 3, 2023
4ebe9aa
Merge pull request #863 from digitalfabrik/IGAPP-1061-upgrade-react-a…
LeandraH Feb 3, 2023
4e5c91c
Merge branch 'main' into IGAPP-1061-upgrade-react-and-react-native
sarahsporck Feb 6, 2023
ac7c2b4
IGAPP-1061: Add file for XCode version
LeandraH Feb 6, 2023
d0eb7a4
IGAPP-1061: Remove file for XCode version
LeandraH Feb 6, 2023
dea4493
Merge branch 'main' into IGAPP-1061-upgrade-react-and-react-native
sarahsporck Feb 6, 2023
705eeff
IGAPP-1061: Install gem for XCode versioning
LeandraH Feb 8, 2023
9116999
IGAPP-1061: Remove XCode in Fastfiles
LeandraH Feb 8, 2023
9c5373b
IGAPP-1061: Downgrade XCode
LeandraH Feb 8, 2023
3817974
IGAPP-1061: Delete package.resolved
LeandraH Feb 8, 2023
1e6fefb
IGAPP-1061: Add previous package.resolved
LeandraH Feb 8, 2023
3e84831
IGAPP-1061: Revert changes in project.pbxproj
LeandraH Feb 9, 2023
bdadc98
IGAPP-1061: Revert changes in package.resolved
LeandraH Feb 9, 2023
bddafdd
IGAPP-1061: Fix warning about scroll throttling
LeandraH Feb 10, 2023
73fdb6b
IGAPP-1061: add project.pbxproj changes for pods
f1sh1918 Feb 10, 2023
2552611
Merge branch 'main' into IGAPP-1061-upgrade-react-and-react-native
LeandraH Feb 13, 2023
854447e
Merge branch 'main' into IGAPP-1061-upgrade-react-and-react-native
f1sh1918 Feb 13, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 18 additions & 18 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ commands:
jobs:
build_android:
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
TOTAL_CPUS: 3
Expand Down Expand Up @@ -355,7 +355,7 @@ jobs:
FL_OUTPUT_DIR: output
TOTAL_CPUS: 4
macos:
xcode: 13.2.1
xcode: 14.2.0
parameters:
build_config_name:
default: integreat
Expand Down Expand Up @@ -420,7 +420,7 @@ jobs:
- notify
build_web:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
environment:
TOTAL_CPUS: 2
parameters:
Expand Down Expand Up @@ -465,7 +465,7 @@ jobs:
- notify
bump_version:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
parameters:
prepare_delivery:
default: false
Expand Down Expand Up @@ -499,7 +499,7 @@ jobs:
- notify
check:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
environment:
TOTAL_CPUS: 1
TZ: Europe/Berlin
Expand Down Expand Up @@ -533,7 +533,7 @@ jobs:
- notify
deliver_android:
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
parameters:
Expand Down Expand Up @@ -580,7 +580,7 @@ jobs:
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
macos:
xcode: 13.2.1
xcode: 14.2.0
parameters:
build_config_name:
default: integreat
Expand Down Expand Up @@ -632,7 +632,7 @@ jobs:
- notify
deliver_web:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
parameters:
delivery:
description: Whether to deliver to production, beta or to webnext.
Expand Down Expand Up @@ -726,7 +726,7 @@ jobs:
- notify
e2e_android:
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
resource_class: small
Expand All @@ -745,7 +745,7 @@ jobs:
- notify
e2e_ios:
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
resource_class: small
Expand All @@ -764,7 +764,7 @@ jobs:
- notify
e2e_web:
docker:
- image: cimg/node:14.19.0-browsers
- image: cimg/node:16.19.0-browsers
- image: selenium/standalone-chrome
resource_class: small
shell: /bin/bash -eo pipefail
Expand All @@ -783,7 +783,7 @@ jobs:
- notify
move_release_notes:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
steps:
- skip_job
Expand All @@ -798,7 +798,7 @@ jobs:
- notify
notify_android:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
parameters:
production_delivery:
description: Whether builds are delivered to the production or beta lane of the play store.
Expand Down Expand Up @@ -826,7 +826,7 @@ jobs:
success_message: <<^ parameters.production_delivery >>[Beta] <</ parameters.production_delivery >>Integreat, Malte and Aschaffenburg ${NEW_VERSION_NAME} have been released successfully on Android!\n${RELEASE_NOTES}\n${ANDROID_ARTIFACT_URLS}
notify_ios:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
parameters:
production_delivery:
description: Whether builds are delivered to the app store or testflight.
Expand Down Expand Up @@ -854,7 +854,7 @@ jobs:
success_message: <<^ parameters.production_delivery >>[Beta] <</ parameters.production_delivery >>Integreat, Malte and Aschaffenburg ${NEW_VERSION_NAME} have been released successfully on iOS!\n${RELEASE_NOTES}\n${IOS_ARTIFACT_URLS}
notify_web:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
parameters:
production_delivery:
description: Whether builds are delivered to production or beta.
Expand Down Expand Up @@ -889,7 +889,7 @@ jobs:
${RELEASE_NOTES}
promote_android:
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
parameters:
Expand Down Expand Up @@ -918,7 +918,7 @@ jobs:
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
macos:
xcode: 13.2.1
xcode: 14.2.0
parameters:
build_config_name:
default: integreat
Expand All @@ -943,7 +943,7 @@ jobs:
- notify
promote_web:
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
shell: /bin/bash -eo pipefail
steps:
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/build_android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ parameters:
enum: [integreat, malte, integreat-e2e, integreat-test-cms, aschaffenburg]
default: integreat
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
resource_class: medium+
environment:
TOTAL_CPUS: 3 # For resource_class medium+, used in metro.config.ci.js. For memory estimations see IGAPP-557
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/build_ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ parameters:
enum: [integreat, malte, integreat-e2e, integreat-test-cms, aschaffenburg]
default: integreat
macos:
xcode: 13.2.1
xcode: 14.2.0
resource_class: medium
environment:
FL_OUTPUT_DIR: output
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/build_web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ parameters:
enum: [integreat, malte, integreat-test-cms, malte-test-cms, aschaffenburg, obdach]
default: integreat
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: medium
environment:
TOTAL_CPUS: 2 # For resource_class medium
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/bump_version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ parameters:
type: boolean
default: false
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
steps:
- skip_job
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/check.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Run checks and tests.
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
environment:
TOTAL_CPUS: 1 # For resource_class small
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/deliver_android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ parameters:
description: Whether to deliver the build to production.
type: boolean
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
resource_class: small
shell: /bin/bash -eo pipefail
environment:
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/deliver_ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ parameters:
description: Whether to deliver the build to production.
type: boolean
macos:
xcode: 13.2.1
xcode: 14.2.0
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
shell: /bin/bash --login -o pipefail
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/deliver_web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ parameters:
enum: [production, beta, webnext]
type: enum
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
shell: /bin/bash -eo pipefail
steps:
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/e2e_android.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
resource_class: small
shell: /bin/bash -eo pipefail
environment:
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/e2e_ios.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
resource_class: small
shell: /bin/bash -eo pipefail
environment:
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/e2e_web.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
docker:
- image: cimg/node:14.19.0-browsers
- image: cimg/node:16.19.0-browsers
- image: selenium/standalone-chrome
resource_class: small
shell: /bin/bash -eo pipefail
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/move_release_notes.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Last step of a production delivery. Move all unreleased release notes to a new directory.
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
steps:
- skip_job
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/notify_android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ parameters:
description: Whether builds are delivered to the production or beta lane of the play store.
type: boolean
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
steps:
- skip_job
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/notify_ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ parameters:
description: Whether builds are delivered to the app store or testflight.
type: boolean
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
steps:
- skip_job
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/notify_web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ parameters:
description: Whether builds are delivered to production or beta.
type: boolean
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
steps:
- skip_job
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/promote_android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ parameters:
enum: [integreat, malte, aschaffenburg]
default: integreat
docker:
- image: cimg/android:2022.03.1-node
- image: cimg/android:2022.09.2-node
resource_class: small
shell: /bin/bash -eo pipefail
environment:
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/promote_ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ parameters:
enum: [integreat, malte, aschaffenburg]
default: integreat
macos:
xcode: 13.2.1
xcode: 14.2.0
environment:
FASTLANE_SKIP_UPDATE_CHECK: true
shell: /bin/bash --login -o pipefail
Expand Down
2 changes: 1 addition & 1 deletion .circleci/src/jobs/promote_web.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
docker:
- image: cimg/node:14.19.0
- image: cimg/node:16.19.0
resource_class: small
shell: /bin/bash -eo pipefail
steps:
Expand Down
9 changes: 8 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,14 @@ module.exports = {
},
overrides: [
{
files: ['*.spec.{ts,tsx}', '**/__mocks__/*.{ts,tsx}', '**/testing/*.{ts,tsx}', 'jest.setup.ts', 'jest.config.ts'],
files: [
'*.spec.{ts,tsx}',
'*.e2e.ts',
'**/__mocks__/*.{ts,tsx}',
'**/testing/*.{ts,tsx}',
'jest.setup.ts',
'jest.config.ts',
],
rules: {
'global-require': 'off',
'no-console': 'off',
Expand Down
2 changes: 1 addition & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ native/android/**/*
native/ios/**/*
native/vendor/**/*

native/assets/licenses.json
native/src/assets/licenses.json
web/assets/licenses.json

web/www/icons
Expand Down
File renamed without changes.
10 changes: 10 additions & 0 deletions api-client/jest.setup.ts
Original file line number Diff line number Diff line change
@@ -1 +1,11 @@
global.fetch = require('jest-fetch-mock')

class FormDataMock {
formData = {}
append(name: string, value: object) {
Object.assign(this.formData, { [name]: value })
}
}

// @ts-expect-error only implement necessary functions
global.FormData = FormDataMock
6 changes: 3 additions & 3 deletions api-client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
"ts:check": "tsc --build"
},
"peerDependencies": {
"react": "17.0.2"
"@types/react": "^18.0.26",
"react": "18.2.0"
},
"dependencies": {
"@turf/distance": "^6.5.0",
Expand All @@ -35,10 +36,9 @@
"@types/js-md5": "^0.4.3",
"@types/lodash": "^4.14.182",
"@types/normalize-path": "^3.0.0",
"@types/react": "^17.0.37",
"@types/seedrandom": "^3.0.2",
"jest-fetch-mock": "^3.0.3",
"jest-junit": "^14.0.0",
"jest-junit": "^15.0.0",
"seedrandom": "^3.0.3"
}
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
/**
* only needed as FormData is a web-specific type
* @jest-environment jsdom
*/
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jest-environment jsdom has been removed from jest. So to avoid adding another dependency I mocked FormData instead.

import createFeedbackEndponit, {
CONTENT_FEEDBACK_CATEGORY,
FeedbackType,
Expand Down
Loading