CodyEngel / fakek

A faker library for Kotlin.
Apache License 2.0
7 stars 6 forks source link

Add fake cryptography #52

Closed RafaelPereiraSantos closed 3 years ago

RafaelPereiraSantos commented 3 years ago

Closes #38

Description

Creates a fake cryptography class that provide random encrypted values

Technical Details

Creates a fake cryptography class that wrap around faker to providing m5, sha1 and sha2 (256 and 512) random values

Code Samples

fun main() {
    val fakeCrypto =  fakek.crypto()
    val message = fakeCrypto.sha512()
    messageSender.prepareMessage(message).send()
    print("super secret message sent")
}

Reviewers: @CodyEngel

RafaelPereiraSantos commented 3 years ago

@CodyEngel

codecov[bot] commented 3 years ago

Codecov Report

Merging #52 into main will increase coverage by 0.07%. The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##               main      #52      +/-   ##
============================================
+ Coverage     98.85%   98.93%   +0.07%     
- Complexity       70       76       +6     
============================================
  Files            17       18       +1     
  Lines           174      187      +13     
  Branches          3        3              
============================================
+ Hits            172      185      +13     
  Misses            1        1              
  Partials          1        1              
Impacted Files Coverage Δ Complexity Δ
src/main/kotlin/dev/fakek/FakeContext.kt 96.96% <100.00%> (+0.19%) 1.00 <0.00> (ø)
src/main/kotlin/dev/fakek/fakes/FakeCrypto.kt 100.00% <100.00%> (ø) 6.00 <6.00> (?)

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 a7139b6...8e8fcbf. Read the comment docs.