question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Brownie - rebuild / expand CLI test cases

See original GitHub issue

The Issue

  1. The test cases in tests/cli/test_cli_main.py are poorly designed. Tests are using a custom class CliTester which provides a similar functionality to monkeypatch.setattr and mocker.spy, but is difficult to understand on first glance.
  2. Test coverage for some cli modules is lacking, especially brownie/_cli/analyze.py and brownie/_cli/ethpm.py.

Completion Requirements

  1. Rewrite tests in tests/cli/test_cli_main.py to use monkeypatch and pytest-mock. The CliTester class should no longer exist.
  2. Increase test coverage for all files in brownie/_cli/ to >=90%

Implementation Notes

Functionality that is exists outside of the brownie/_cli/ folder is already covered elsewhere in the test suite. To maximize speed of the tests, you should patch these methods. The important thing is to verify that the CLI is correctly calling the intended methods.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
gitcoinbotcommented, Dec 29, 2019

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


The funding of 0.351 ETH (46.8 USD @ $133.35/ETH) attached to this issue has been approved & issued to @agbilotia1998.

1reaction
agbilotia1998commented, Dec 14, 2019

@iamdefinitelyahuman sure, will let you know.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Brownie Documentation
Brownie is a Python-based development and testing framework for smart contracts targeting the Ethereum Virtual.
Read more >
brownie/CHANGELOG.md at master - GitHub
A Python-based development and testing framework for smart contracts targeting the Ethereum Virtual Machine. - brownie/CHANGELOG.md at ...
Read more >
Testing with Brownie - YouTube
Brownie is an important framework for smart contract developers. In this tutorial, learn how to test with Brownie and ensure your smart ...
Read more >
eth-brownie Changelog - pyup.io
Fixed - Bug when determining dependencies of a `Contract` object [1.6.7](https://github.com/eth-brownie/brownie/tree/v1.6.7) - 2020-03-09
Read more >
Owner's Manual - Brownie's THIRD LUNG
Each chapter concludes with a multiple choice quiz to test your ... The remote intake staff is designed to increase compressor life by...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found