harmony-one / bounties

Bounty program is to help the community take part in the development of the Harmony blockchain. It covers from core feature to validator tooling, from dApp development to DeFi integration.
MIT License
59 stars 23 forks source link

Add Unit Test to harmony-one/core packages #67

Open jacksteroo opened 3 years ago

jacksteroo commented 3 years ago

Description

Add unit test to the harmony-one/core packages. There are some examples of completed unit tests but should be reviewed as well. Increase the test coverage on packages on core to 90% coverage.

Context

Unit tests improves code quality and should follow the F.I.R.S.T. principles

Acceptance Criteria

Reward

USD $750 (in ONEs)

gitcoinbot commented 3 years ago

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


This issue now has a funding of 5139.4396 ONE (753.99 USD @ $0.15/ONE) attached to it.

gitcoinbot commented 3 years ago

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


Work has been started.

These users each claimed they can complete the work by 264 years, 10 months from now. Please review their action plans below:

1) rohaquinlop has started work.

This bounty looks pretty interesting, I'll start reading the repository and the F.I.R.S.T. Principles and read the tests that are implemented about the methods and functions.

After the first stage, then I'll start coding the tests and create the PR to the repo. 2) zedgell has started work.

I will generate unit test and publish to GitHub 3) seinsidler has started work.

I'm going to add unit tests in the core package for what is left. Currently, there are several "*_test.go" files already in the package, so I'll keep this format for my unit tests. I'll try to go for the parts of the package that haven't been touched and at some point in this process, I should reach out to the others who said they are working on this to make sure we aren't overlapping too much on the tests we are writing! 4) rioelder has started work.

How do I earn? Plus I don't really understand how things work here. 5) dfreilich has started work.

As an experienced Go engineer, I am familiar with the process of creating additional Go tests (having previously bumped coverage of multiple repos to >80%). As such, I will:

1). Review the F.I.R.S.T. principles they specifically requested 2) Look at the current code coverage, and add tests to cover larger swaths of code first 3) Once I have a core of tests, narrow them in to create the desired test coverage. 6) millsmcilroy has started work.

1) Read the README.md and CONTRIBUTING.md carefully 2) Quickly familiarize myself with the basic concepts of the Harmony blockchain at https://docs.harmony.one/home/ 3) Examine the existing unit tests and see how close they already are to the F.I.R.S.T. principle 4) Dive in and start writing unit tests. In my experience, if the goal is 90% coverage, you need to shoot for 100%, just in case you come across some code that can't be efficiently unit tested without a refactor. 5) Hopefully catch some bugs along the way! 7) graomelo has started work.

I can perform the described task, I can also check the dependencies. 8) codegazer584 has started work.

Hi, I would like to start working on this task.

My action plan would be go through the existing unit tests carefully and add more unit tests that follow F.I.R.S.T principles.

If approved, I can start working on it immediately. 9) kattparkhurst98 has started work.

i plan on running the code through visual code and increasing the 90% and making sure there no other error 10) jf2978 has started work.

familiarize myself with the repo, look for test coverage gaps (namely in tx_pool_test.go), write a test

Learn more on the Gitcoin Issue Details page.