Comments (5)
I think a simple fix would be replacing the above line with:
test -z "$TEST_LONG" || test_set_prereq EXPENSIVE
Will push a PR with something like the above.
CC @moy
from sharness.
Why not come back to a plain "if/then"? I find it more readable than your fix, which is somehow a double-negation (I read it as "unless $TEST_LONG
is not set, run test_set_prereq ...").
from sharness.
Another option would be to end the script with :
, which is commonly done in init scripts exactly for that purpose.
from sharness.
Yeah, ending the script with :
is a good idea and can be done instead or on top of PR #48.
I think I will do that soon.
About using if/then/fi
I don't think it is enough, because people might be later tempted to simplify it again into using just &&
.
from sharness.
Fixed by PR #49 (sharness: properly ensure it ends with code 0).
from sharness.
Related Issues (20)
- make test fails with unliked SHELL_PATH HOT 9
- add --tee option from git test-lib.sh HOT 1
- sharness.sh is executable? HOT 3
- Release tarballs are not signed HOT 4
- Clarify purpose of "aggregate-results.sh" HOT 12
- Cleanup actions are only run if no tests failed HOT 8
- Additional test function for string comparison? HOT 5
- Document usage of "trash" directory HOT 2
- Document how to release a new Sharness version HOT 2
- Line feed regression HOT 3
- Lots of dangling branches HOT 2
- SHARNESS_TEST_SRCDIR and extensions HOT 3
- Sharness self-test fails HOT 2
- Can't locate object method "follower" via package "IO::Pty"
- test_expect_failure test 2 = 2 does not fail with prove HOT 4
- trash dir as home dir when run on Windows HOT 1
- testing scripts with sourced functions HOT 1
- Make a release v1.2 HOT 1
- Usage with `prove` would need more documentation HOT 6
- Calling functions from Git submodule fails with v1.2.0 release (Regression) HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sharness.