Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch all LevelDB stores in unit tests to memory database #441

Closed
antonlerner opened this issue Jan 14, 2019 · 7 comments
Closed

Switch all LevelDB stores in unit tests to memory database #441

antonlerner opened this issue Jan 14, 2019 · 7 comments

Comments

@antonlerner
Copy link
Contributor

antonlerner commented Jan 14, 2019

Overview / Motivation

We shouldn't use any persistent parts in our unit tests

The Task

Currently, we use database.NewLevelDbStore to create the DB for meshDB in the unit tests,
We should use only MemoryDB for unit tests.
Replace all occurrences of database.NewLevelDbStore in out unit tests to MemDatabase

Time Estimation

4 hours

Implementation Notes

check out block_listener_test.go

Contribution Guidelines

Important: Issue assignment to developers will be by the order of their application and proficiency level according to the tasks complexity. We will not assign tasks to developers who have'nt introduced themselves on our Gitter dev channel

  1. Introduce yourself on go-spacemesh dev chat channel - ask our team any question you may have about this task
  2. Fork branch develop to your own repo and work in your repo
  3. You must document all methods, enums and types with godoc comments
  4. You must write go unit tests for all types and methods when submitting a component, and integration tests if you submit a feature
  5. When ready for code review, submit a PR from your repo back to branch develop
  6. Attach relevant issue to PR
@gitcoinbot
Copy link

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


This issue now has a funding of 0.3 ETH (36.27 USD @ $120.9/ETH) attached to it as part of the Spacemesh - https://spacemesh.io fund.

@gitcoinbot
Copy link

gitcoinbot commented Jan 16, 2019

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


Work has been started.

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

1) alonp99 has been approved to start work.

Hey, I would like to take this one :)

Learn more on the Gitcoin Issue Details page.

2) techswappy has applied to start work (Funders only: approve worker | reject worker).

Familiar with in-memory database usage and how to migrate it. Can explore the codebase to understand the specific requirement here.

Learn more on the Gitcoin Issue Details page.

@almogdepaz
Copy link
Contributor

almogdepaz commented Jan 17, 2019

@antonlerner an integration test should be add instead
use
if testing.Short() {
t.Skip()
}

in the start of it

@gitcoinbot
Copy link

@alonp99 Hello from Gitcoin Core - are you still working on this issue? Please submit a WIP PR or comment back within the next 3 days or you will be removed from this ticket and it will be returned to an ‘Open’ status. Please let us know if you have questions!

  • reminder (3 days)
  • escalation to mods (6 days)

Funders only: Snooze warnings for 1 day | 3 days | 5 days | 10 days | 100 days

@alonp99
Copy link
Contributor

alonp99 commented Jan 20, 2019

@gitcoinbot working on it

@gitcoinbot
Copy link

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


Work for 0.3 ETH (34.74 USD @ $115.79/ETH) has been submitted by:

  1. @alonp99

@avive please take a look at the submitted work:


@gitcoinbot
Copy link

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


The funding of 0.3 ETH (34.13 USD @ $113.78/ETH) attached to this issue has been approved & issued to @alonp99.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants