Сryptocurrency development analysis

# What was the problem?
Rewards for round 1 were applied twice during snapshotting.
### How did I fix it?
Forced sumRound to return `0` when round is summed just after genesis block (dummy round 1 for electing delegates).
### How to test it?
– Run test suite.
– Run migration and check results manually.
### Review checklist

* The PR solves #2126
* All new code is covered with unit tests
* All new code was formatted with Prettier
* Linting passes
* Tests pass
* Commit messages follow the [commit guidelines](CONTRIBUTING.md#git-commit-messages)
* Documentation has been added/updated

You can view, comment on, or merge this pull request online at:

https://github.com/LiskHQ/lisk/pull/2127

— Commit Summary —

* Manual sum round when sumRound is executed just after genesis block
* Add test case for modules/rounds unit tests for sumRound just after genesis block
* Extend snapshotting functional system tests with sending transaction at round 1
* Set reward and fee for sumRound just after genesis block to 0
* Update create_rounds_rewards_table migration
* Fix typo in SQL query

— File Changes —

M db/sql/migrations/updates/20180205000003_create_rounds_rewards_table.sql (8)
M modules/rounds.js (10)
M test/functional/system/snapshotting.js (31)
M test/unit/modules/rounds.js (101)

— Patch Links —

https://github.com/LiskHQ/lisk/pull/2127.patch
https://github.com/LiskHQ/lisk/pull/2127.diff

This post was last modified on June 14, 2018, 9:05 am

Categories: cryptocurrency