Add a with-hooks test.
parent
c47d0a1e6e
commit
bff78ccc21
@ -0,0 +1,12 @@
|
||||
[general]
|
||||
directory = "hooked"
|
||||
|
||||
[[pre_commit]]
|
||||
name = "Pre Commit 1"
|
||||
command = "exit 0"
|
||||
on_failure = "continue"
|
||||
|
||||
[[pre_commit]]
|
||||
name = "Pre Commit 2"
|
||||
script = "test.sh"
|
||||
on_failure = "stop"
|
@ -0,0 +1,35 @@
|
||||
---
|
||||
source: tests/parsing.rs
|
||||
expression: config
|
||||
---
|
||||
Config {
|
||||
general: General {
|
||||
directory: "hooked",
|
||||
},
|
||||
pre_commit: [
|
||||
PreCommit {
|
||||
name: Some(
|
||||
"Pre Commit 1",
|
||||
),
|
||||
on_failure: Continue,
|
||||
task: Task {
|
||||
command: Some(
|
||||
"exit 0",
|
||||
),
|
||||
script: None,
|
||||
},
|
||||
},
|
||||
PreCommit {
|
||||
name: Some(
|
||||
"Pre Commit 2",
|
||||
),
|
||||
on_failure: Stop,
|
||||
task: Task {
|
||||
command: None,
|
||||
script: Some(
|
||||
"test.sh",
|
||||
),
|
||||
},
|
||||
},
|
||||
],
|
||||
}
|
Loading…
Reference in New Issue