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

Integrate contracts v2.2.0 #1845

Merged
merged 66 commits into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from 56 commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
87a7a01
Created AccessList contract.
mariacarmina Aug 22, 2024
a460ed9
Created new Datatoken4 template.
mariacarmina Aug 26, 2024
fdcad34
set file object fc.
mariacarmina Aug 26, 2024
5b40e64
integrated datatoken 4 contract.
mariacarmina Aug 26, 2024
25a42c8
install new version of ocean contracts.
mariacarmina Sep 2, 2024
e59d565
added sapphire sdk + remove private functions.
mariacarmina Sep 2, 2024
a1e8179
tweaks of template4.
mariacarmina Sep 3, 2024
243cadb
wrap signer on access list contract.
mariacarmina Sep 3, 2024
8cfbeae
Added minimum gas fees for sapphire networks. Send function.
mariacarmina Sep 3, 2024
f751cc2
Convert to contract functions. Remove abiEnterprise.
mariacarmina Sep 3, 2024
47500b0
Upgraded contracts v2.2.0.
mariacarmina Sep 4, 2024
9695585
Integrated Access List factory. Created tests.
mariacarmina Sep 4, 2024
fc985b9
Rename file.
mariacarmina Sep 4, 2024
ab9898d
Add script for testing sapphire functionality.
mariacarmina Sep 4, 2024
8e636e5
Remove sapphire sdk from accesslist contract.
mariacarmina Sep 4, 2024
0924a71
Added new functions to access list contract.
mariacarmina Sep 4, 2024
65f5aaa
Remove script.
mariacarmina Sep 4, 2024
7653cc2
Remove script.
mariacarmina Sep 4, 2024
cec7a26
Increase timeout to the tests.
mariacarmina Sep 5, 2024
f336192
Added js script. Modified gitignore.
mariacarmina Sep 5, 2024
59bdf3d
Install tsx, added oasis testnet into config helpers.
mariacarmina Sep 5, 2024
e8d4749
Modified provider signature.
mariacarmina Sep 5, 2024
e2004b6
fix lint.
mariacarmina Sep 6, 2024
2bca54e
Fix type module.
mariacarmina Sep 6, 2024
c2c41e2
commented ordering other assets different than URL.
mariacarmina Sep 6, 2024
54b7731
Added check for file object for template index.
mariacarmina Sep 6, 2024
4125959
fix deploy erc20 template 4 test.
mariacarmina Sep 9, 2024
f97666c
Calculate index function. Fix review.
mariacarmina Sep 11, 2024
b287294
Change to this.signer.
mariacarmina Sep 11, 2024
fe18feb
Uncommented orders.
mariacarmina Sep 11, 2024
874226c
Upgrade Github actions.
mariacarmina Sep 11, 2024
7b84b3c
Condition for calculation of template index.
mariacarmina Sep 11, 2024
da25e32
Specify ABI in the tests.
mariacarmina Sep 11, 2024
73988cd
Test w soulbound contracts.
mariacarmina Sep 11, 2024
5e96dda
Fixed wallet address for test.
mariacarmina Sep 11, 2024
2670863
Add deny list check.
mariacarmina Sep 11, 2024
f88cdb0
Store access list address within the constructor. Added tests.
mariacarmina Sep 11, 2024
6fe2e0b
add debug log.
mariacarmina Sep 12, 2024
2fdaed9
Create new datatoken for consumer.
mariacarmina Sep 12, 2024
74ddb70
distinguish coverage reports.
mariacarmina Sep 12, 2024
42bbd15
Fix coverage download report.
mariacarmina Sep 12, 2024
76c2539
cleanup. added tests.
mariacarmina Sep 13, 2024
c3f50bc
fix tests.
mariacarmina Sep 15, 2024
4b1f4c4
Remove unused imports.
mariacarmina Sep 16, 2024
c6f5657
Increase timeout.
mariacarmina Sep 16, 2024
a3d8346
Added test with encrypted tx.
mariacarmina Sep 16, 2024
1e7c377
comment the test file.
mariacarmina Sep 17, 2024
f871aff
Add test back + add ABI.
mariacarmina Sep 17, 2024
81ec8c4
added debug log.
mariacarmina Sep 17, 2024
b3694a2
increase timeout.
mariacarmina Sep 17, 2024
badeacb
Comment tests with external services.
mariacarmina Sep 17, 2024
c1b5a48
fix graphql URL.
mariacarmina Sep 17, 2024
b612061
Insert arweave.
mariacarmina Sep 17, 2024
62c3d56
Insert ipfs.
mariacarmina Sep 17, 2024
fb1f02d
cleanup. mention ipfs issue.
mariacarmina Sep 17, 2024
58298e4
Fixes. Added getFilesObject back.
mariacarmina Sep 17, 2024
ae1e79f
fix review.
mariacarmina Sep 19, 2024
f595def
replace srv id w srv index.
mariacarmina Sep 19, 2024
2da79fa
Fix doc.
mariacarmina Sep 19, 2024
15aaddb
Remove wrap call from constructor.
mariacarmina Sep 19, 2024
9584d32
Modify README.
mariacarmina Sep 19, 2024
c88123a
Added check for tx.
mariacarmina Sep 24, 2024
54e15f8
fix check.
mariacarmina Sep 24, 2024
a6620c9
Fix conflicts.
mariacarmina Sep 24, 2024
27aa6bb
remove duplicate test.
mariacarmina Sep 24, 2024
2e02dfc
Merge branch 'main' into integrate-contracts-v2.2.0
mariacarmina Sep 26, 2024
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
29 changes: 16 additions & 13 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ jobs:

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v2
- uses: actions/setup-node@v4
with:
node-version: '20'
- name: Cache node_modules
uses: actions/cache@v2
uses: actions/cache@v4
env:
cache-name: cache-node-modules
with:
Expand Down Expand Up @@ -71,21 +71,21 @@ jobs:
ls -la "$HOME/.ocean/ocean-contracts/artifacts/"
- run: npm run build:metadata
- run: npm run test:unit:cover
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: coverage
name: coverage-unit
path: coverage/

test_integration:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v2
- uses: actions/setup-node@v4
with:
node-version: '20'
- name: Cache node_modules
uses: actions/cache@v2
uses: actions/cache@v4
env:
cache-name: cache-node-modules
with:
Expand Down Expand Up @@ -143,9 +143,9 @@ jobs:
run: docker logs ocean_aquarius_1 && docker logs ocean_provider_1 && docker logs ocean_provider2_1 && docker logs ocean_computetodata_1
if: ${{ failure() }}
- name: Upload coverage
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: coverage
name: coverage-integration
path: coverage/

build:
Expand All @@ -159,11 +159,11 @@ jobs:

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v2
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
- name: Cache node_modules
uses: actions/cache@v2
uses: actions/cache@v4
env:
cache-name: cache-node-modules
with:
Expand All @@ -180,9 +180,12 @@ jobs:
if: ${{ success() && github.actor != 'dependabot[bot]' }}
steps:
- uses: actions/checkout@v3
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: coverage
name: coverage-unit
- uses: actions/download-artifact@v4
with:
name: coverage-integration

- uses: paambaati/[email protected]
env:
Expand All @@ -197,7 +200,7 @@ jobs:
needs: [test_unit, test_integration]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v2
- uses: actions/setup-node@v4
with:
node-version: '20'

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v2
- uses: actions/setup-node@v4
with:
node-version: '20'
registry-url: https://registry.npmjs.org/
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ dist/
.nyc_output/
coverage/
doc/
test/**/*.js
test/unit/*.js
test/integration/*.js
mariacarmina marked this conversation as resolved.
Show resolved Hide resolved
src/**/*.js

src/metadata\.json
Expand Down
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,21 @@ npm run test:integration
npm run test:integration:cover
```

### Sapphire Integration Tests

Currently, there is used Oasis Sapphire Test network, please export the `PRIVATE_KEY` before testing.
mariacarmina marked this conversation as resolved.
Show resolved Hide resolved

```bash
export PRIVATE_KEY='0x<YOUR_PRIVATE_KEY>'
```

Then, you can execute the tests individually with:

```bash
npm run test:sapphire
```


> Note: On macOS, changes to the `provider`, `metadataCache` and `subgraph` URLs are required, as their default `barge` IPs can not be accessed due to network constraints on macOS. Instead use `http://127.0.0.1` for each direct call to the mentioned services, but keep the internal `provider` URL (`http://172.15.0.4:8030`) hardcoded inside all DDO's `serviceEndpoint`, and when calling `nft.setMetadata()`.

## 🛳 Production
Expand Down
Loading
Loading