NagRock / ts-mockito

Mocking library for TypeScript
MIT License
969 stars 93 forks source link

Fix problem with a mock resolving a mocked value with Promises #192

Closed jlkeesey closed 4 years ago

jlkeesey commented 4 years ago

The long description is in #191 so this is short.

This fixes a problem where returning a mocked object through thenResolve() on another mocked object never resolves.

codecov-commenter commented 4 years ago

Codecov Report

Merging #192 into master will decrease coverage by 0.55%. The diff coverage is 20.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #192      +/-   ##
==========================================
- Coverage   93.55%   92.99%   -0.56%     
==========================================
  Files          34       34              
  Lines         652      657       +5     
  Branches       80       82       +2     
==========================================
+ Hits          610      611       +1     
- Misses         30       32       +2     
- Partials       12       14       +2     
Impacted Files Coverage Δ
src/Mock.ts 91.83% <20.00%> (-2.53%) :arrow_down:

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 6637048...4d3ce94. Read the comment docs.

jlkeesey commented 4 years ago

I only added tests so I don't know why the coverage is down and I only added 6 lines (7 if you count the variable definition).

jlkeesey commented 4 years ago

Something isn't working, my environment may be wrong. I'm going to close this until I can figure out what is going on.