Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use default FileAlg to implement MockFileAlg, take 2 #1962

Merged
merged 2 commits into from
Feb 24, 2021

Conversation

fthomas
Copy link
Member

@fthomas fthomas commented Feb 24, 2021

This changes MockFileAlg such that it not only modifies the MockState but also files in the filesystem via the default FileAlg implementation. The main motivation for this change is to make using actual Git commands in tests possible. Another advantage is that we increase the coverage of the default FileAlg. A disadvantage is that tests can now be influenced by existing or deleted files. So we need to be more careful now that tests do not write files in the same location.

@codecov
Copy link

codecov bot commented Feb 24, 2021

Codecov Report

Merging #1962 (79d97e8) into master (cc9750b) will increase coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1962      +/-   ##
==========================================
+ Coverage   78.35%   78.40%   +0.04%     
==========================================
  Files         129      129              
  Lines        2227     2227              
  Branches       60       60              
==========================================
+ Hits         1745     1746       +1     
+ Misses        482      481       -1     
Impacted Files Coverage Δ
.../main/scala/org/scalasteward/core/io/FileAlg.scala 96.87% <0.00%> (+3.12%) ⬆️

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 cc9750b...79d97e8. Read the comment docs.

@fthomas fthomas added this to the 0.10.0 milestone Feb 24, 2021
@fthomas fthomas merged commit b14d044 into master Feb 24, 2021
@fthomas fthomas deleted the topic/ioFileAlg-in-MockFileAlg-2 branch February 24, 2021 19:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant