Rework asLatest update (#2802)

* Revert "[CI Skip] release/beta 2.4.2-10"

This reverts commit 5cb1c2d33a.

* Revert "Use asLatest in metadata extraction (#2800)"

This reverts commit 600666de1c.

* Bumps

* Expansion

* Flatten

* Metadata class imports

* Cleanup Decorate exports

* Move Metadata to top-level

* Swap logger on ABI

* Adjust imports

* Cleanups

* Updates
This commit is contained in:
Jaco Greeff
2020-10-29 11:59:37 +01:00
committed by GitHub
parent 5cb1c2d33a
commit ea3ee428d8
81 changed files with 217 additions and 234 deletions
+17
View File
@@ -0,0 +1,17 @@
// Copyright 2017-2020 @polkadot/metadata authors & contributors
// SPDX-License-Identifier: Apache-2.0
import { TypeRegistry } from '@polkadot/types';
import substrateData from './static';
import Metadata from './Metadata';
describe('Metadata', (): void => {
it('allows creation from hex with JSON equivalence', (): void => {
const test = new Metadata(new TypeRegistry(), substrateData);
expect(
new Metadata(new TypeRegistry(), test.toHex()).toJSON()
).toEqual(test.toJSON());
});
});