Skip to content

Commit

Permalink
Merge pull request #14 from terra-money/fix/ibc/url
Browse files Browse the repository at this point in the history
Breaking changes with new Core
  • Loading branch information
emidev98 authored Apr 25, 2023
2 parents 8ec4495 + 9c9889e commit cdd69d2
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 17 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@terra-money/feather.js",
"version": "1.0.0-beta.15",
"version": "1.0.1",
"description": "The JavaScript SDK for Terra and Feather chains",
"license": "MIT",
"author": "Terraform Labs, PTE.",
Expand Down Expand Up @@ -30,7 +30,7 @@
},
"scripts": {
"build": "tsc --module commonjs && webpack --mode production",
"test": "jest",
"test": "jest --runInBand",
"format": "prettier --check ./src/**/*.ts",
"format:fix": "prettier --write ./src/**/*.ts",
"lint": "eslint src --ext .js,.ts",
Expand Down
5 changes: 4 additions & 1 deletion src/client/lcd/api/IbcAPI.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,10 @@ export class IbcAPI extends BaseAPI {
params: APIParams = {}
): Promise<IbcClientParams> {
return this.getReqFromChainID(chainID)
.get<{ params: IbcClientParams.Data }>(`/ibc/client/v1/params`, params)
.get<{ params: IbcClientParams.Data }>(
`/ibc/core/client/v1/params`,
params
)
.then(({ params: d }) => ({
allowed_clients: d.allowed_clients,
}));
Expand Down
2 changes: 1 addition & 1 deletion src/client/lcd/api/StakingAPI.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const checkDelegations = (delegations: Delegation[]) => {
// };

const delegator = test1.accAddress('terra');
const validator = 'terravaloper1gtw2uxdkdt3tvq790ckjz8jm8qgwkdw3uptstn';
const validator = 'terravaloper1zdpgj8am5nqqvht927k3etljyl6a52kwqndjz2';

describe('StakingAPI', () => {
it('parameters', async () => {
Expand Down
2 changes: 1 addition & 1 deletion src/client/lcd/api/UpgradeAPI.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ describe('UpgradeAPI', () => {

describe('node_versions', () => {
it('module count', async () => {
expect(await upgrade.moduleVersions('pisco-1')).toHaveLength(21);
expect(await upgrade.moduleVersions('pisco-1')).toHaveLength(26);
});
});
});
2 changes: 1 addition & 1 deletion src/core/TxInfo.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ describe('TxInfo', () => {
});

it('parses events correctly', () => {
const tx = TxInfo.fromData(instantiateContractTxAmino as TxInfo.Data, true);
const tx = TxInfo.fromData(instantiateContractTxAmino as any, true);

if (!tx.logs) {
throw new Error('logs undefined');
Expand Down
10 changes: 5 additions & 5 deletions src/core/authz/msgs/MsgExecAuthorized.spec.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
//import { MsgExecAuthorized } from './MsgExecAuthorized';
//const examples = require('./MsgExecAuthorized.data.json');
import { MsgExecAuthorized } from './MsgExecAuthorized';
const examples = require('./MsgExecAuthorized.data.json');

/*
describe('MsgExecAuthorized', () => {
it('deserializes', () => {
examples.forEach((data: MsgExecAuthorized.Amino) => {
expect(MsgExecAuthorized.fromAmino(data, true).toAmino(true)).toEqual(data);
expect(MsgExecAuthorized.fromAmino(data, true).toAmino(true)).toEqual(
data
);
});
});
});
*/
3 changes: 1 addition & 2 deletions src/key/MnemonicKey.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,9 @@ describe('MnemonicKey', () => {
mnemonic:
'island relax shop such yellow opinion find know caught erode blue dolphin behind coach tattoo light focus snake common size analyst imitate employ walnut',
});
const { accAddress } = mk;

const msgSend = new MsgSend(
accAddress('terra'),
mk.accAddress('terra'),
'terra1wg2mlrxdmnnkkykgqg4znky86nyrtc45q336yv',
new Coins({ uluna: '100000000' })
);
Expand Down
3 changes: 1 addition & 2 deletions src/key/RawKey.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,9 @@ describe('RawKey', () => {
'island relax shop such yellow opinion find know caught erode blue dolphin behind coach tattoo light focus snake common size analyst imitate employ walnut',
});
const rk = new RawKey(mk.privateKey);
const { accAddress } = rk;

const msgSend = new MsgSend(
accAddress('terra'),
rk.accAddress('terra'),
'terra1wg2mlrxdmnnkkykgqg4znky86nyrtc45q336yv',
new Coins({ uluna: '100000000' })
);
Expand Down

0 comments on commit cdd69d2

Please sign in to comment.