iota-java icon indicating copy to clipboard operation
iota-java copied to clipboard

Issue-174: Mock iota client in integration tests

Open ezienecker opened this issue 4 years ago • 5 comments

Description of change

Mock iota client in integration test

Type of change

Choose a type of change, and delete any options that are not relevant.

  • Enhancement (a non-breaking change which adds functionality)

How the change has been tested

Running the tests.

Make sure to provide instructions for the maintainer as well as any relevant configurations.

Change checklist

Add an x to the boxes that are relevant to your changes, and delete any items that are not.

  • [x] My code follows the contribution guidelines for this project
  • [x] I have performed a self-review of my own code
  • [x] I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation -> not needed
  • [ ] I have added tests using ginkgo that prove my fix is effective or that my feature works -> not needed
  • [x] New and existing unit tests pass locally with my changes

ezienecker avatar Oct 11 '20 17:10 ezienecker

Codacy Here is an overview of what got changed by this pull request:


Issues
======
+ Solved 6
- Added 56
           

Complexity increasing per file
==============================
- jota/src/test/java/org/iota/jota/IotaMultiSigTest.java  1
         

Clones added
============
- jota/src/test/java/org/iota/jota/IotaAPITest.java  2
- jota/src/test/java/org/iota/jota/IotaMultiSigTest.java  2
         

See the complete overview on Codacy

kwek20 avatar Oct 11 '20 17:10 kwek20

I am not sure if the checks regarding the assertions are useful. On the one hand this contradicts the Clean Code concept by saying that the methods should be named in a way that they make a statement about what the method does (What is tested?). On the other hand I doubt the quality of the messages.

ezienecker avatar Oct 16 '20 09:10 ezienecker

Yea thanks for the Codacy fixes you did, I'm honestly just surprised it decided to work suddenly :) Ill test and review in the weekend as I'm currently a bit busy with Streams, but this is a great help! Especially when we move forward with chrysalis 2.0. Could you solve the conflicts though? If not, ill do it later :)

kwek20 avatar Oct 16 '20 19:10 kwek20

@kwek20 now it should be fine

ezienecker avatar Oct 19 '20 18:10 ezienecker

@ezienecker Thanks for the ping 🙏 On it!

kwek20 avatar Oct 19 '20 19:10 kwek20