Skip to content
This repository was archived by the owner on Nov 10, 2023. It is now read-only.

(Feature) Add unit tests#1230

Merged
dasanra merged 73 commits intodevelopmentfrom
remove-ganache
Sep 14, 2020
Merged

(Feature) Add unit tests#1230
dasanra merged 73 commits intodevelopmentfrom
remove-ganache

Conversation

@Agupane
Copy link
Contributor

@Agupane Agupane commented Aug 11, 2020

Description

Added unit tests for the following files:

  • AddressBookUtils.ts
  • fetchSafeTokens.ts
  • tokenHelpers.ts
  • ethAddresses.ts
  • transactionHelpers.ts
  • actions/utils.ts
  • safeBalances.ts

Also added types for addressBook and fixed a bug on the isERC721Contract method

I tried to avoid the interaction with web3, just tested our logic and added some mock functions for transactions, safeInstance

Please ignore the branch name, it was intended to be a ganache removal pr but then we discussed internally that will be better if we just start adding easy-tests as a first approach to have a basis and then we could start another pr with more complex tests

@Agupane Agupane self-assigned this Aug 11, 2020
@github-actions
Copy link

CLA Assistant Lite All Contributors have signed the CLA.

@github-actions
Copy link

github-actions bot commented Aug 11, 2020

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 2 0
Ignored 8 N/A
  • Result: ✅ success

  • Annotations: 2 total


[warning] @typescript-eslint/explicit-module-boundary-types

Require explicit return and argument types on exported functions' and classes' public class methods


Report generated by eslint-plus-action

@ghost
Copy link

ghost commented Aug 11, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

1 similar comment
@ghost
Copy link

ghost commented Aug 11, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

@ghost
Copy link

ghost commented Aug 11, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

@ghost
Copy link

ghost commented Aug 11, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

Adds isModifySettingsTransaction tests
Adds isMultiSendTransaction tests
Adds isUpgradeTransaction tests
Adds isOutgoingTransaction tests
Adds isCustomTransaction tests
…to remove-ganache

# Conflicts:
#	src/logic/addressBook/utils/index.ts
#	src/logic/safe/store/actions/utils.ts
#	src/routes/safe/components/Balances/SendModal/screens/AddressBookInput/index.tsx
#	src/test/safe.dom.balances.ts
@ghost
Copy link

ghost commented Sep 10, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

1 similar comment
@ghost
Copy link

ghost commented Sep 10, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

@ghost
Copy link

ghost commented Sep 10, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

@Agupane Agupane requested a review from mmv08 September 11, 2020 12:37
@Agupane
Copy link
Contributor Author

Agupane commented Sep 11, 2020

Hey @mikheevm just ping you to ask if you are able to check this pr or we should merge it

@Agupane Agupane requested a review from mmv08 September 14, 2020 12:52
@github-actions
Copy link

github-actions bot commented Sep 14, 2020

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 2 0
Ignored 9 N/A
  • Result: ✅ success

  • Annotations: 2 total


[warning] @typescript-eslint/explicit-module-boundary-types

Require explicit return and argument types on exported functions' and classes' public class methods


Report generated by eslint-plus-action

@ghost
Copy link

ghost commented Sep 14, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

Copy link
Contributor

@mmv08 mmv08 left a comment

Choose a reason for hiding this comment

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

This was a very hard one, thank you!
one last comment, please

@ghost
Copy link

ghost commented Sep 14, 2020

Travis automatic deployment:
https://pr1230--safereact.review.gnosisdev.com/app

@dasanra dasanra merged commit f1916e9 into development Sep 14, 2020
@dasanra dasanra deleted the remove-ganache branch September 14, 2020 15:59
@github-actions github-actions bot locked and limited conversation to collaborators Sep 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants