BlockNumber, Nonce -> u32 (#1284)

* BlockNumber -> u32

* Interface types extend, not re-use

* Merge master, rebuild

* Merge typo

* Lazy create struct types (extended definitions)

* Cleanup tests for Nonce u32

* Remove polkadot u64 BlockNumber (substrate default)

* Warn on type dup & still clear

* Allow type overrides to work at any point
This commit is contained in:
Jaco Greeff
2019-08-11 15:07:00 +02:00
committed by GitHub
parent 1aa7899a7a
commit e5cc6836eb
17 changed files with 126 additions and 84 deletions
@@ -16,6 +16,6 @@ const consts = fromMetadata(metadata);
describe('fromMetadata', (): void => {
it('should return constants with the correct type and value', (): void => {
expect(consts.democracy.cooloffPeriod).toBeInstanceOf(ClassOf('BlockNumber'));
expect(consts.democracy.cooloffPeriod.toHex()).toEqual('0x0000000000062700');
expect(consts.democracy.cooloffPeriod.toHex()).toEqual('0x00062700');
});
});