-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
18 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
. "$(dirname -- "$0")/functions.sh" | ||
setup | ||
install | ||
|
||
npx --no-install husky install | ||
|
||
# Test core.hooksPath | ||
expect_hooksPath_to_be ".husky" | ||
|
||
# Test pre-commit | ||
git add package.json | ||
npx --no-install husky add .husky/pre-commit "echo \"pre-commit\" && exit 1" | ||
time expect 1 "git commit -m foo" | ||
|
||
# Uninstall | ||
npx --no-install husky uninstall | ||
expect 1 "git config core.hooksPath" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters