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

test: e2e-tests #561

Merged
merged 12 commits into from
May 31, 2021
2 changes: 1 addition & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
**/build/*
calc
docs
runtime-tests
e2e-tests
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/.vscode
**/node_modules
/build
/runtime-tests/build
/e2e-tests/build
/target
yarn-error.log
**/*.rs.bk
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ All the commits in this repo follow the [Conventional Commits spec](https://www.
* @polkadot/apps-config [release notes](https://github.com/polkadot-js/apps/releases)
* @polkadot/util-crypto [release notes](https://github.com/polkadot-js/common/releases)

1. After updating the dependencies, the next step is making sure the release will work against all noted runtimes for Polkadot, Kusama, and Westend. This can be handled by running `yarn test:init-runtime-tests`. You must have `python3`, and the dependencies inside of `./scripts/requirements.txt` installed to run the script (Read the [README](./scripts/README.md) for more instructions). Before moving forward ensure all tests pass, and if it warns of any missing types feel free to make an issue [here](https://github.com/paritytech/substrate-api-sidecar/issues).
1. After updating the dependencies, the next step is making sure the release will work against all noted runtimes for Polkadot, Kusama, and Westend. This can be handled by running `yarn test:init-e2e-tests`. You must have `python3`, and the dependencies inside of `./scripts/requirements.txt` installed to run the script (Read the [README](./scripts/README.md) for more instructions). Before moving forward ensure all tests pass, and if it warns of any missing types feel free to make an issue [here](https://github.com/paritytech/substrate-api-sidecar/issues).

1. Update the version in the package.json (this is very important for releasing on NPM).

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ChainSpec } from '../types';
import { kusamaEndpoints } from './kusamaEndpoints';
import { polkadotEndpoints } from './polkadotEndpoints';
import { westendEndpoints } from './westendEndpoints';
import { kusamaEndpoints } from './kusama';
import { polkadotEndpoints } from './polkadot';
import { westendEndpoints } from './westend';

export const endpoints: Record<ChainSpec, string[][]> = {
kusama: kusamaEndpoints,
Expand Down
216 changes: 216 additions & 0 deletions e2e-tests/endpoints/kusama/2350438.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,216 @@
{
"number": "2350438",
"hash": "0xa28e220e4dba37deedc112dd09e819586a4210558194ebb1d3d56f7ff9a46436",
"parentHash": "0xfa0206856121840531a9028a4a097e5f28a9586314590d2cddf84facaa325f43",
"stateRoot": "0xfe35f5313f93452d6a836cac1c7c46e420142ea319ab7b600e41111547bf26c1",
"extrinsicsRoot": "0xb6b77ea6fc75d1c132da1ffbdf0eaee165aceaed5b31333d7796159e8b48d7a0",
"authorId": "DAT4gSgyMskggCmTQKfEM6hQgRy1NWdhtfMTAuPLsUAGUPy",
"logs": [
{
"type": "PreRuntime",
"index": "6",
"value": [
"0x42414245",
"0x027e000000f8ebca0f00000000"
]
},
{
"type": "Seal",
"index": "5",
"value": [
"0x42414245",
"0x02ad7cc03cdcaf56dfe0ada0f49c865fdc0169d437c5ed55452f2aebb458782d4bf6baa8c1e6404c1a39ef9a29f92b78a90444b82fc2306bb1001466fa1ac789"
]
}
],
"onInitialize": {
"events": []
},
"extrinsics": [
{
"method": {
"pallet": "timestamp",
"method": "set"
},
"signature": null,
"nonce": null,
"args": {
"now": "1589741520000"
},
"tip": null,
"hash": "0x71db73f038bd790ada81a40728825857a49d543ab40c5b63de69b8588737712f",
"info": {},
"events": [
{
"method": {
"pallet": "system",
"method": "ExtrinsicSuccess"
},
"data": [
{
"weight": "159000000",
"class": "Mandatory",
"paysFee": "Yes"
}
]
}
],
"success": true,
"paysFee": false
},
{
"method": {
"pallet": "finalityTracker",
"method": "finalHint"
},
"signature": null,
"nonce": null,
"args": {
"hint": "2350435"
},
"tip": null,
"hash": "0x47db276250fd90bd16a5e62592531bb7f41fd0c350b3bff388d4e8accf8116c3",
"info": {},
"events": [
{
"method": {
"pallet": "system",
"method": "ExtrinsicSuccess"
},
"data": [
{
"weight": "0",
"class": "Mandatory",
"paysFee": "Yes"
}
]
}
],
"success": true,
"paysFee": false
},
{
"method": {
"pallet": "parachains",
"method": "setHeads"
},
"signature": null,
"nonce": null,
"args": {
"heads": []
},
"tip": null,
"hash": "0xcf52705d1ade64fc0b05859ac28358c0770a217dd76b75e586ae848c56ae810d",
"info": {},
"events": [
{
"method": {
"pallet": "system",
"method": "ExtrinsicSuccess"
},
"data": [
{
"weight": "1000000000",
"class": "Mandatory",
"paysFee": "Yes"
}
]
}
],
"success": true,
"paysFee": false
},
{
"method": {
"pallet": "balances",
"method": "transfer"
},
"signature": {
"signature": "0x530726ec5e7e673a892c5f1c416a069a152ca02c29aae9616f8c9daf8053ca101ea75d4920edef1d513d84332bd5ed9a8c1b5b15f9efe9f7c46af68da3c5850e",
"signer": "D87rkSMaPmdA3sdxL6CbXw6SUWhvTTpdw8qXiUcMwsKPDwy"
},
"nonce": "0",
"args": {
"dest": "FUkSMaDdhWEdJJ3F59zhVRACpHa3qk35AG7ZTVpyConuEFi",
"value": "90000000000"
},
"tip": "0",
"hash": "0x3f5a8e3b5dae4e28252d98e8464f29b50b08a49a36cf71ac009c9a791c1ffa82",
"info": {
"weight": "195000000",
"class": "Normal",
"partialFee": "3333333"
},
"events": [
{
"method": {
"pallet": "balances",
"method": "DustLost"
},
"data": [
"D87rkSMaPmdA3sdxL6CbXw6SUWhvTTpdw8qXiUcMwsKPDwy",
"9000000000"
]
},
{
"method": {
"pallet": "system",
"method": "KilledAccount"
},
"data": [
"D87rkSMaPmdA3sdxL6CbXw6SUWhvTTpdw8qXiUcMwsKPDwy"
]
},
{
"method": {
"pallet": "balances",
"method": "Transfer"
},
"data": [
"D87rkSMaPmdA3sdxL6CbXw6SUWhvTTpdw8qXiUcMwsKPDwy",
"FUkSMaDdhWEdJJ3F59zhVRACpHa3qk35AG7ZTVpyConuEFi",
"90000000000"
]
},
{
"method": {
"pallet": "treasury",
"method": "Deposit"
},
"data": [
"800000000"
]
},
{
"method": {
"pallet": "balances",
"method": "Deposit"
},
"data": [
"DAT4gSgyMskggCmTQKfEM6hQgRy1NWdhtfMTAuPLsUAGUPy",
"200000000"
]
},
{
"method": {
"pallet": "system",
"method": "ExtrinsicSuccess"
},
"data": [
{
"weight": "195000000",
"class": "Normal",
"paysFee": "Yes"
}
]
}
],
"success": true,
"paysFee": true
}
],
"onFinalize": {
"events": []
},
"finalized": true
}
Loading