5afe / svalinn-kotlin

πŸ›‘οΈβ„οΈοΈ Kotlin libraries for Ethereum based Android development
MIT License
31 stars 3 forks source link

Ethereum RPC API migration to a coroutine implementation #43

Closed jpalvarezl closed 4 years ago

jpalvarezl commented 4 years ago

Closes https://github.com/gnosis/svalinn-kotlin/issues/39 .

Changes proposed in this pull request:

@gnosis/mobile-devs

Tests still need to be transalated to coroutines, there are 2 that have already been migrated as example.

codecov-io commented 4 years ago

Codecov Report

Merging #43 into master will decrease coverage by 7.87%. The diff coverage is 24.44%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master      #43      +/-   ##
============================================
- Coverage     62.39%   54.52%   -7.88%     
- Complexity      152      157       +5     
============================================
  Files            54       55       +1     
  Lines          1351     1460     +109     
  Branches        223      228       +5     
============================================
- Hits            843      796      -47     
- Misses          407      563     +156     
  Partials        101      101              
Impacted Files Coverage Ξ” Complexity Ξ”
...ereum/rpc/retrofit/RetrofitEthereumRpcConnector.kt 14.28% <0.00%> (-85.72%) 6.00 <5.00> (ΓΈ)
...ava/pm/gnosis/ethereum/rpc/EthereumRpcConnector.kt 0.00% <0.00%> (ΓΈ) 0.00 <0.00> (ΓΈ)
...pm/gnosis/ethereum/rpc/co/RpcEthereumRepository.kt 5.37% <5.37%> (ΓΈ) 5.00 <5.00> (?)
...pm/gnosis/ethereum/rpc/rx/RpcEthereumRepository.kt 99.02% <100.00%> (ΓΈ) 10.00 <6.00> (?)
...main/java/pm/gnosis/ethereum/EthereumRepository.kt 62.96% <100.00%> (ΓΈ) 0.00 <0.00> (ΓΈ)
...ava/pm/gnosis/ethereum/rpc/models/JsonRpcResult.kt 8.10% <0.00%> (-70.28%) 3.00% <0.00%> (-1.00%)
...pto/src/main/java/pm/gnosis/crypto/utils/Curves.kt 100.00% <0.00%> (ΓΈ) 3.00% <0.00%> (ΓΈ%)
...rc/main/java/pm/gnosis/crypto/LinuxSecureRandom.kt 0.00% <0.00%> (ΓΈ) 0.00% <0.00%> (ΓΈ%)
...gnosis/svalinn/security/impls/AndroidKeyStorage.kt 0.00% <0.00%> (ΓΈ) 0.00% <0.00%> (ΓΈ%)
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more Ξ” = absolute <relative> (impact), ΓΈ = not affected, ? = missing data Powered by Codecov. Last update 0b861ab...d5223f6. Read the comment docs.

jpalvarezl commented 4 years ago

While developping https://github.com/gnosis/safe-android/issues/557 I also realised that it would be nice to make all the EthRequest subclasses into data classes for ease of testing.

rmeissner commented 4 years ago

Could you give the PR a little bit more descriptive title? :)