Closed mstade closed 6 years ago
Merging #50 into master will increase coverage by
0.14%
. The diff coverage is100%
.
@@ Coverage Diff @@
## master #50 +/- ##
=========================================
+ Coverage 95.06% 95.2% +0.14%
=========================================
Files 15 15
Lines 324 334 +10
=========================================
+ Hits 308 318 +10
Misses 16 16
Impacted Files | Coverage Δ | |
---|---|---|
src/cli/opts.js | 100% <ø> (ø) |
:arrow_up: |
src/main.js | 97.32% <100%> (+0.26%) |
:arrow_up: |
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 4e72767...e97439d. Read the comment docs.
Description
These changes allow a user to run an arbitrary command on the successful result of an interactive build. This is useful to for instance kick off tests every time a watched source file changes. Consider the following collection of scripts:
In this, the
test:dev
script kicks off thebuild
script, which simply builds the project with default settings, but it also enables interactive mode and tells ez-build to run the commandnpm run -s test | tap-dot
whenever it successfully builds a file. This has the effect of running all tests whenever a source file changes and is successfully built.Motivation and Context
It's a common use case to run some command whenever a build is successful, typically running tests or the likes to ensure changes don't cause unwanted failures. It's really only relevant to do this on successful builds, since broken files won't run anyway.
How Was This Tested?
CLI tests were added to test against a project fixture, and unit tests were added to ensure we parse the CLI option properly.
Types of changes
Checklist: