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

0xError tests #48

Merged
merged 4 commits into from
Jul 18, 2022
Merged

0xError tests #48

merged 4 commits into from
Jul 18, 2022

Conversation

W3stside
Copy link
Contributor

@W3stside W3stside commented Jul 12, 2022

Adds tests for the 0xError class

Added this based on the 0x error doc

@W3stside W3stside mentioned this pull request Jul 12, 2022
2 tasks
@coveralls
Copy link
Collaborator

coveralls commented Jul 12, 2022

Coverage Status

Coverage increased (+2.6%) to 77.241% when pulling 35d65a0 on 0x-api-error-tests into 8692ef6 on 0x-api.

@github-actions
Copy link

github-actions bot commented Jul 12, 2022

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 0 0
Ignored 0 N/A
  • Result: ✅ success
  • Annotations: 0 total

Report generated by eslint-plus-action

@W3stside W3stside marked this pull request as ready for review July 12, 2022 12:24
src/api/0x/0x.spec.ts Outdated Show resolved Hide resolved
src/api/0x/0x.spec.ts Outdated Show resolved Hide resolved
@W3stside W3stside merged commit eeee1a4 into 0x-api Jul 18, 2022
@W3stside W3stside deleted the 0x-api-error-tests branch July 18, 2022 18:54
W3stside added a commit that referenced this pull request Jul 18, 2022
* removed unnecessary code + minor test

* adding 0x API pt.1

* adding 0x types

simplify

logic update

add types

* add utils to normalise quote

* add zeroxApi

* add zeroXSDK

* tests

fix 0x spec

rebase fix

remove test re-added during rebase

fix constructor & getQuote + rearrange

* add ZeroXError

* add error test

update tests

* update 0xError handling

* add zero0x api to cowsdk

* pr comments

* pass chainId to 0x api

* update test

* create separate utils file for 0x

* update affiliateAddressMap type

* modify api to address PR comments

* 0xError tests (#48)

* 0x error tests

* fix test to use cowsdk

* fix tests according to comments

* better tests
W3stside added a commit that referenced this pull request Jul 18, 2022
* create BaseApi

* CowApi extends BaseApi

- pass base url and name in constructor
- baseUrl includes api version
- remove base fns from CowApi

* removed unnecessary code + minor test

* fix test to use BaseApi

* revert type

* add defaultHeaders to constructor and as optional params to fetch

* remove appId check in tests

* remove useless base spec test

* add market util

* fix small error

* SIMPLIFY AND RENAME

* fix small changes post merge

* protect methods

* add market utils test

* simplify/organise baseApi

* organise & override Cow/BaseApi methods

* add option to override apiUrl params

* fix private 'this' type

* reqOptions > requestOptions

* Add 0xApi & Errors (#47)

* removed unnecessary code + minor test

* adding 0x API pt.1

* adding 0x types

simplify

logic update

add types

* add utils to normalise quote

* add zeroxApi

* add zeroXSDK

* tests

fix 0x spec

rebase fix

remove test re-added during rebase

fix constructor & getQuote + rearrange

* add ZeroXError

* add error test

update tests

* update 0xError handling

* add zero0x api to cowsdk

* pr comments

* pass chainId to 0x api

* update test

* create separate utils file for 0x

* update affiliateAddressMap type

* modify api to address PR comments

* 0xError tests (#48)

* 0x error tests

* fix test to use cowsdk

* fix tests according to comments

* better tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants