Commit Graph

311 Commits

Author SHA1 Message Date
shashankshampi c67d4030ac parent 3179532b64
author shashankshampi <shashank.sanket1995@gmail.com> 1729780155 +0530
committer shashankshampi <shashank.sanket1995@gmail.com> 1730274350 +0530

test: Code Migration from status-cli-tests
fix_: functional tests (#5979)

* fix_: generate on test-functional

* chore(test)_: fix functional test assertion

---------

Co-authored-by: Siddarth Kumar <siddarthkay@gmail.com>

feat(accounts)_: cherry-pick Persist acceptance of Terms of Use & Privacy policy (#5766) (#5977)

* feat(accounts)_: Persist acceptance of Terms of Use & Privacy policy (#5766)

The original GH issue https://github.com/status-im/status-mobile/issues/21113
came from a request from the Legal team. We must show to Status v1 users the new
terms (Terms of Use & Privacy Policy) right after they upgrade to Status v2
from the stores.

The solution we use is to create a flag in the accounts table, named
hasAcceptedTerms. The flag will be set to true on the first account ever
created in v2 and we provide a native call in mobile/status.go#AcceptTerms,
which allows the client to persist the user's choice in case they are upgrading
(from v1 -> v2, or from a v2 older than this PR).

This solution is not the best because we should store the setting in a separate
table, not in the accounts table.

Related Mobile PR https://github.com/status-im/status-mobile/pull/21124

* fix(test)_: Compare addresses using uppercased strings

---------

Co-authored-by: Icaro Motta <icaro.ldm@gmail.com>

test_: restore account (#5960)

feat_: `LogOnPanic` linter (#5969)

* feat_: LogOnPanic linter

* fix_: add missing defer LogOnPanic

* chore_: make vendor

* fix_: tests, address pr comments

* fix_: address pr comments

fix(ci)_: remove workspace and tmp dir

This ensures we do not encounter weird errors like:
```
+ ln -s /home/jenkins/workspace/go_prs_linux_x86_64_main_PR-5907 /home/jenkins/workspace/go_prs_linux_x86_64_main_PR-5907@tmp/go/src/github.com/status-im/status-go
ln: failed to create symbolic link '/home/jenkins/workspace/go_prs_linux_x86_64_main_PR-5907@tmp/go/src/github.com/status-im/status-go': File exists
script returned exit code 1
```

Signed-off-by: Jakub Sokołowski <jakub@status.im>

chore_: enable windows and macos CI build (#5840)

- Added support for Windows and macOS in CI pipelines
- Added missing dependencies for Windows and x86-64-darwin
- Resolved macOS SDK version compatibility for darwin-x86_64

The `mkShell` override was necessary to ensure compatibility with the newer
macOS SDK (version 11.0) for x86_64. The default SDK (10.12) was causing build failures
because of the missing libs and frameworks. OverrideSDK creates a mapping from
the default SDK in all package categories to the requested SDK (11.0).

fix(contacts)_: fix trust status not being saved to cache when changed (#5965)

Fixes https://github.com/status-im/status-desktop/issues/16392

cleanup

added logger and cleanup

review comments changes

fix_: functional tests (#5979)

* fix_: generate on test-functional

* chore(test)_: fix functional test assertion

---------

Co-authored-by: Siddarth Kumar <siddarthkay@gmail.com>

feat(accounts)_: cherry-pick Persist acceptance of Terms of Use & Privacy policy (#5766) (#5977)

* feat(accounts)_: Persist acceptance of Terms of Use & Privacy policy (#5766)

The original GH issue https://github.com/status-im/status-mobile/issues/21113
came from a request from the Legal team. We must show to Status v1 users the new
terms (Terms of Use & Privacy Policy) right after they upgrade to Status v2
from the stores.

The solution we use is to create a flag in the accounts table, named
hasAcceptedTerms. The flag will be set to true on the first account ever
created in v2 and we provide a native call in mobile/status.go#AcceptTerms,
which allows the client to persist the user's choice in case they are upgrading
(from v1 -> v2, or from a v2 older than this PR).

This solution is not the best because we should store the setting in a separate
table, not in the accounts table.

Related Mobile PR https://github.com/status-im/status-mobile/pull/21124

* fix(test)_: Compare addresses using uppercased strings

---------

Co-authored-by: Icaro Motta <icaro.ldm@gmail.com>

test_: restore account (#5960)

feat_: `LogOnPanic` linter (#5969)

* feat_: LogOnPanic linter

* fix_: add missing defer LogOnPanic

* chore_: make vendor

* fix_: tests, address pr comments

* fix_: address pr comments

chore_: enable windows and macos CI build (#5840)

- Added support for Windows and macOS in CI pipelines
- Added missing dependencies for Windows and x86-64-darwin
- Resolved macOS SDK version compatibility for darwin-x86_64

The `mkShell` override was necessary to ensure compatibility with the newer
macOS SDK (version 11.0) for x86_64. The default SDK (10.12) was causing build failures
because of the missing libs and frameworks. OverrideSDK creates a mapping from
the default SDK in all package categories to the requested SDK (11.0).

fix(contacts)_: fix trust status not being saved to cache when changed (#5965)

Fixes https://github.com/status-im/status-desktop/issues/16392

test_: remove port bind

chore(wallet)_: move route execution code to separate module

chore_: replace geth logger with zap logger (#5962)

closes: #6002

feat(telemetry)_: add metrics for message reliability (#5899)

* feat(telemetry)_: track message reliability

Add metrics for dial errors, missed messages,
missed relevant messages, and confirmed delivery.

* fix_: handle error from json marshal

chore_: use zap logger as request logger

iterates: status-im/status-desktop#16536

test_: unique project per run

test_: use docker compose v2, more concrete project name

fix(codecov)_: ignore folders without tests

Otherwise Codecov reports incorrect numbers when making changes.
https://docs.codecov.com/docs/ignoring-paths

Signed-off-by: Jakub Sokołowski <jakub@status.im>

test_: verify schema of signals during init; fix schema verification warnings (#5947)

fix_: update defaultGorushURL (#6011)

fix(tests)_: use non-standard port to avoid conflicts

We have observed `nimbus-eth2` build failures reporting this port:
```json
{
  "lvl": "NTC",
  "ts": "2024-10-28 13:51:32.308+00:00",
  "msg": "REST HTTP server could not be started",
  "topics": "beacnde",
  "address": "127.0.0.1:5432",
  "reason": "(98) Address already in use"
}
```
https://ci.status.im/job/nimbus-eth2/job/platforms/job/linux/job/x86_64/job/main/job/PR-6683/3/

Signed-off-by: Jakub Sokołowski <jakub@status.im>

fix_: create request logger ad-hoc in tests

Fixes `TestCall` failing when run concurrently.

chore_: configure codecov (#6005)

* chore_: configure codecov

* fix_: after_n_builds
2024-10-30 13:23:09 +05:30
Igor Sirotin 42022599e8
fix_: no test reporting to codecov (#5968) 2024-10-21 12:33:27 +01:00
Igor Sirotin 9f564010da
chore_: configure tests develop job (#5956)
* refactor_: rename isTestNightlyJob

* chore_: configure develop tests job

* chore_: isPRJob and getAmountToKeep
2024-10-19 12:01:28 +03:00
Igor Sirotin c1dd9397f7
refactor_: remove generated files from source control (#5878)
* fix_: gitignore generated files

* chore_: delete generated files

* fix_: update go generate instructions

* feat(Makefile)_: clean-generated-files target

* feat(Makefile)_: `generate` target

* fix(Makefile)_: dependent generate target

* ci_: run generate, update docker file deps

* fix(Makefile)_: remove `clean-generated-files` target

* fix(Makefile)_: simpler GO_GENERATE_CMD arg

* fix_: temp workspace GO_GENERATE_FAST_DIR
2024-10-03 20:59:44 +01:00
Igor Sirotin ae2ec8f369
chore_: rename integration tests to functional tests (#5908) 2024-10-03 14:51:51 +01:00
Igor Sirotin 031b5342f1
chore_: move/rename files messing generation (#5897)
* refactor_: rename migrations file

* refactor_: move generate_handlers to cmd

* fix_: makefile generate_handlers path
2024-09-30 19:19:36 +01:00
Igor Sirotin d794e43347
feat_: functional tests coverage (#5805)
* feat_: functional tests coverage

* fix_: codecov yaml
2024-09-24 16:33:26 +01:00
Siddarth Kumar a7daee3dae
chore(docker)_: use llvm instead of gcc 2024-09-24 17:52:17 +05:30
richΛrd a84f78f8aa
fix_: remove unreachable code error message (#5845) 2024-09-23 09:12:02 -04:00
Igor Sirotin 946ee4e496
feat_: improve PR commit messages processing (#5835)
* fix_: commit-messages github action

* fix_: prevent -> avoid

* fix_: use curly braces
2024-09-18 23:33:48 +01:00
Igor Sirotin f859b58c38
fix(tag_version)_: properly calculate version tag (#5834) 2024-09-13 16:51:36 +01:00
Igor Sirotin 43353e036f
fix(tag_version)_: bump major version on breaking change (#5829) 2024-09-13 15:54:37 +01:00
Igor Sirotin bcaf8ebbe6
fix_: tag version script (#5823) 2024-09-11 09:54:44 +01:00
Igor Sirotin 00db9c8a9b
fix(run_unit_tests)_: don't exit in nightly runs (#5808) 2024-09-09 16:28:10 +01:00
Igor Sirotin ea290d97ef
feat_: Integrate Codecov (#5796)
* feat_: added `codecov-cli` nix derivation

* feat_: added simple codecov configuration

* feat_: add UNIT_TEST_REPORT_CODECOV ci flag

* feat_: upload logs and reports to codecov
2024-09-05 10:11:16 +01:00
Igor Sirotin 6287b5fcf7
fix(run_unit_tests.sh)_: proper exit code on test fail (#5797) 2024-09-04 11:24:26 +01:00
Igor Sirotin 7623f68679
fix_: nightly test runs (#5791)
* fix_: run nightly protocol tests as separate processes

* fix_: calculate timeout

* fix_: TEST_WITH_COVERAGE_REPORTS_DIR

* fix_: proper filter protocol package

* chore_: log run_unit_tests stages

* fix_: coverage reports merging

* chore_: more logs

* chore_: fix typo

* chore_: increase test timeouts

* fix_: properly filter packages

* feat_: UNIT_TEST_DRY_RUN flag for tests run

* fix_: UNIT_TEST_PACKAGES_FILTERED calculation

* fix_: remove the force-run waku test first

* fix_: delete unused file
2024-09-03 12:50:09 +01:00
Igor Sirotin 28e7a364c7
chore(test_stats)_: better stats, print skipped tests (#5781)
* chore(test_stats)_: better stats, list skipped tests

* chore_: add skip reasons to some tests
2024-08-29 21:09:26 +01:00
Igor Sirotin 666f07fe1e
fix_: nightly tests report (#5779) 2024-08-29 11:48:32 +01:00
Igor Sirotin 85fba77b7d
chore_: bring back jenkins commit check (#5777) 2024-08-27 23:40:17 +01:00
Igor Sirotin 8491e76a34
fix_: separate commit message check (#5773)
* chore_: add github action conventional commits

* chore_: remove commit check from tests run

* fix_: continue checking commits when breaking change found

* fix_: don't run check on pr edit
2024-08-27 22:42:06 +01:00
Igor Sirotin cc722359b5
chore_: run tests concurrently (#5731)
* chore_: fake flaky tests

* chore_: run tests in parallel (wip)

* chore_: test-with-coverage-old

* chore_: lint-fix fake flaky tests

* chore_: cleanup

* chore_:

* chore_: lint-fix fake flaky tests

* chore_: enable running some tests sequentially

* chore_: enable back all tests

* chore_: no sequential packages

* chore_: cleanup

* chore_: remove fake flaky packages

* chore_: cleanup

* chore_: attempt UNIT_TEST_COUNT as test count

* chore_: spawn multiple processes

* fix_: don't spawn multiple processes

* chore_: revert redirect_stdout changes

* fix_: update Jenkinsfile

* fix_: use env variables

* fix_: typo
2024-08-26 10:03:26 +01:00
Patryk Osmaczko 8914a79284 chore(ci)_: adjust nightly tests build retention to 14 runs
Increased build and artifact retention, as more context is usually
needed when analyzing flakiness thorugh nightly tests.
2024-08-21 15:32:55 +02:00
Jakub Sokołowski bc984e0cb1
chore(ci)_: fix formatting, bump library version
Also drop unused `_assets/ci/validate-vendor.sh` script.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2024-08-20 09:40:22 +02:00
Igor Sirotin ef85895f65
fix_: pass proper version to params (#5735)
* fix_: pass proper version to params

* fix_: use --dirty flag

* fix_: delete version_test

* fix_: pass proper version to artifacts
2024-08-19 16:47:11 +01:00
richΛrd a6645bd209
chore_: remove `status.test` fleet (#5702) 2024-08-16 14:26:35 -04:00
richΛrd bb6d5f602b
chore_: fix `TestBasicWakuV2` (#5718) 2024-08-15 14:43:37 -04:00
Igor Sirotin 93bb77f303
chore_: change patch version to 0 when incrementing minor (#5719) 2024-08-15 18:36:52 +01:00
Andrea Maria Piana 771f26210a Set BASE_BRANCH to develop if not defined 2024-08-14 19:55:09 +01:00
Igor Sirotin dd443b030d
fix(commit_check)_: use proper base branch (#5700) 2024-08-13 10:58:48 +01:00
dlipicar b9d083c6d5
feat(wallet): add split onramp url endpoint (#5656)
* feat(wallet)_: add split onramp url endpoint & fix onrmap url
2024-08-12 12:53:32 +00:00
Mykhailo Prakhov 58a9557c58
fix: reject handling requests to join without revealed accounts (#5549)
* fix(requestToJoin)_: request to join must have revealed addresses with signature

* fix(tests)_: fix tests

* chore(tests)_: increase tests timeout
2024-08-07 17:57:02 +02:00
frank 79d9262430
fix_:increase timeout on unit test (#5553) 2024-07-22 19:08:47 +08:00
frank 4a43b2b2be
fix_:still return the image when handleAccountInitialsImpl is unable to get public key to generate color hash to generate ring (#5409)
* fix_:still return the image when handleAccountInitialsImpl unable to get public key

* test_:add unit test for handleAccountInitialsImpl

* test_:improve unit test

* fix_:still return the image when handleAccountImagesImpl unable to get public key
2024-07-19 16:41:45 +08:00
Igor Sirotin 325429b218
chore_: add test-coverage.html report (#5490) 2024-07-10 13:37:50 +01:00
Jakub Sokołowski 0d82dbe240 feat(ci)_: add Jenkinsfile, Dockerfile for RPC tests
Also add curl to Docker image.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2024-07-04 16:14:02 +02:00
Jakub Sokołowski 5fd1c06bce
fix(ci)_: bump lib to 1.9.1 to make uploads public
Depends on:
https://github.com/status-im/status-jenkins-lib/commit/ab9aa93c

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2024-07-01 19:33:26 +02:00
Jakub Sokołowski 6e52565356
feat(ci)_: use s5cmd instead of s3cmd
It's actively maintained and has better concurrency support.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2024-07-01 09:49:10 +02:00
Jakub Sokołowski 769ea7799b
feat(ci)_: add ansiColor(xterm) for nice colors
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2024-07-01 09:47:53 +02:00
Jakub Sokołowski b6d2b9eb53
fix(ci)_: fix Nix version label and bump library
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2024-06-26 17:55:26 +02:00
Igor Sirotin e2846f3936
chore_: exclude cmd from test coverage (#5427) 2024-06-26 17:16:16 +02:00
Andrea Maria Piana 5cfaa00195 chore_: Add script for extracting logs 2024-06-24 11:56:57 +01:00
Igor Sirotin 61322b8dab fix_: catching gotestsum exit code 2024-06-21 12:10:44 +01:00
Igor Sirotin a049f0b688
fix_: include coverage from all packages (#5390) 2024-06-20 21:35:35 +01:00
Igor Sirotin d00df557c7
fix_: final coverage reports merging (#5384) 2024-06-19 17:57:44 +01:00
Igor Sirotin d2f4cae18f
fix: merge coverage reports from each test rerun (#5360)
* fix_: fix test coverage when rerunning tests

* fix_: make lint-fix

* chore_: change test coverage report artifact name

* chore_: added codeclimate.json to artifacts

* chore_: bring in gocovmerge util

---------

Co-authored-by: Siddarth Kumar <siddarthkay@gmail.com>
2024-06-19 11:40:52 +01:00
Patryk Osmaczko e9882e88d3 chore(ci)_: archive logs in case of test failure 2024-06-17 17:17:54 +02:00
Anton Danchenko 74e9ce93bf
test(wallet)_: status-go integration tests (#5302) 2024-06-11 13:36:20 +02:00
Siddarth Kumar 8e53f62331
chore_: set $GIT_COMMIT for codeclimate (#5315)
When Jenkins creates a build, it can sometimes run the build on a detached HEAD, causing the commit SHA to be different from the SHA of your branch. This will cause issues when reporting test coverage to Code Climate.

Setting `GIT_COMMIT` fixes code climate upload errors.

ref -> https://docs.codeclimate.com/docs/jenkins#jenkins-ci-builds

Closes #5294
2024-06-10 07:30:10 +05:30
Patryk Osmaczko c2f5bdb907 chore(scripts)_: extend tests timeout to 35mins 2024-06-07 23:46:20 +02:00