Skip to content

Commit

Permalink
Merge pull request #244 from neutron-org/feat/use-neutronjs
Browse files Browse the repository at this point in the history
feat: use neutronjs in sdk47 #ntrn-147
  • Loading branch information
pr0n00gler authored Dec 8, 2023
2 parents 891f554 + e86a49f commit a1da4e8
Show file tree
Hide file tree
Showing 199 changed files with 4,518 additions and 401,031 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,14 @@ NO_DOCKER=1 yarn test # all tests
...
```

## Development

If you're developing integration tests and need to add additional helper methods to the @neutron-org/neutronjs packages, start by cloning the package repository. Use the command git clone [email protected]:neutron-org/neutronjs.git. After cloning, you have two options: either alter the package reference in the package.json file to point to your cloned repository, or use yarn link.

Once the JavaScript helper code in your local repository is ready, your next step is to create a Pull Request (PR). This PR must be reviewed and approved before it can be merged into the main branch.

However, even after the merge, you cannot immediately use the new package version in your integration tests. First, you need to wait until the updated version of the package will be published to the npmjs repository. After the new version has been published, you can incorporate it into your integration tests. This will allow you to complete the testing sequence in your GitHub Actions workflow.

## Warning

Since docker-compose doesn't rebuild images on file changing, there is a chance for one to launch the tests with an
Expand Down
59 changes: 0 additions & 59 deletions gen-proto-ibc-go.sh

This file was deleted.

57 changes: 0 additions & 57 deletions gen-proto-pob.sh

This file was deleted.

42 changes: 0 additions & 42 deletions gen-proto.sh

This file was deleted.

4 changes: 2 additions & 2 deletions globalSetup.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { setup } from './src/helpers/env';
import { env } from '@neutron-org/neutronjsplus';

export default async () => {
const host1 = process.env.NODE1_URL || 'http://localhost:1317';
const host2 = process.env.NODE2_URL || 'http://localhost:1316';
!process.env.NO_DOCKER && (await setup(host1, host2));
!process.env.NO_DOCKER && (await env.setup(host1, host2));
};
19 changes: 10 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"scripts": {
"test": "yarn test:parallel && yarn test:run_in_band",
"test:parallel": "jest -b src/testcases/parallel",
"test:run_in_band": "yarn test:tge:auction && yarn test:tge:airdrop && yarn test:tge:credits && yarn test:interchaintx && yarn test:interchain_kv_query && yarn test:interchain_tx_query_plain && yarn test:tokenomics && yarn test:reserve && yarn test:ibc_hooks && yarn test:float",
"test:run_in_band": "yarn test:tge:auction && yarn test:tge:airdrop && yarn test:tge:credits && yarn test:interchaintx && yarn test:interchain_kv_query && yarn test:interchain_tx_query_plain && yarn test:tokenomics && yarn test:reserve && yarn test:ibc_hooks && yarn test:float && yarn test:parameters",
"test:simple": "jest -b src/testcases/parallel/simple",
"test:stargate_queries": "jest -b src/testcases/parallel/stargate_queries",
"test:interchaintx": "jest -b src/testcases/run_in_band/interchaintx",
Expand All @@ -29,27 +29,29 @@
"test:tge:vesting_lp_vault": "jest -b src/testcases/parallel/tge.vesting_lp_vault",
"test:tge:credits_vault": "jest -b src/testcases/parallel/tge.credits_vault",
"test:tge:investors_vesting_vault": "jest -b src/testcases/parallel/tge.investors_vesting_vault",
"test:voting_registry": "jest -b src/testcases/parallel/voting_registry",
"test:float": "NO_WAIT_CHANNEL1=1 NO_WAIT_HTTP2=1 NO_WAIT_CHANNEL2=1 NO_WAIT_DELAY=1 jest -b src/testcases/run_in_band/float",
"gen:proto": "bash ./gen-proto.sh",
"lint": "eslint ./src",
"fmt": "eslint ./src --fix"
},
"author": "Neutron",
"license": "Apache-2.0",
"dependencies": {
"@babel/plugin-transform-modules-commonjs": "^7.18.6",
"@cosmos-client/core": "^0.47.1",
"@cosmos-client/cosmwasm": "^0.40.1",
"@cosmos-client/core": "^0.47.4",
"@cosmos-client/cosmwasm": "^0.40.3",
"@cosmos-client/ibc": "^1.2.1",
"@neutron-org/neutronjsplus": "0.1.0",
"@types/lodash": "^4.14.182",
"@types/long": "^4.0.2",
"axios": "^0.27.2",
"babel-jest": "^29.3.1",
"commander": "^10.0.0",
"date-fns": "^2.16.1",
"express": "^4.18.2",
"jest": "^27.5.1",
"jest-junit": "^15.0.0",
"jest": "^29.7.0",
"jest-junit": "^16.0.0",
"jest-extended": "^4.0.2",
"lodash": "^4.17.21",
"long": "^5.2.1",
"merkletreejs": "^0.3.9",
Expand All @@ -59,14 +61,13 @@
"@babel/preset-env": "^7.20.2",
"@babel/preset-typescript": "^7.18.6",
"@types/express": "^4.17.9",
"@types/jest": "^28.1",
"@types/jest": "^29.5",
"@typescript-eslint/eslint-plugin": "^5.19.0",
"@typescript-eslint/parser": "^5.19.0",
"core-js": "^3.23.5",
"eslint": "^8.13.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-prettier": "^4.0.0",
"jest-extended": "^3.0.2",
"lint-staged": "^12.3.8",
"prettier": "^2.6.2",
"regenerator-runtime": "^0.13.9",
Expand All @@ -84,6 +85,6 @@
]
},
"engines": {
"node": ">=11.0 <17"
"node": ">=16.0 <17"
}
}
Loading

0 comments on commit a1da4e8

Please sign in to comment.