fix(dsh): ясное сообщение о невалидном источнике (#49)
This commit is contained in:
parent
12f19b1de5
commit
ab458b58d2
@ -138,7 +138,7 @@ explicit_source_name() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
report_invalid_explicit_source() {
|
report_invalid_explicit_source() {
|
||||||
echo "FAIL: explicit superpowers source $(explicit_source_name) has no using-superpowers/SKILL.md (expected <dir>/skills/... or <dir>/...)" >&2
|
echo "FAIL: explicit superpowers source is invalid: $(explicit_source_name) has no using-superpowers/SKILL.md (expected <dir>/skills/... or <dir>/...)" >&2
|
||||||
}
|
}
|
||||||
|
|
||||||
check() {
|
check() {
|
||||||
|
|||||||
@ -231,7 +231,7 @@ test('an invalid explicit source fails without touching the legacy cache', () =>
|
|||||||
const run = runInstaller(home, ['--skills', '--superpowers-from', empty])
|
const run = runInstaller(home, ['--skills', '--superpowers-from', empty])
|
||||||
const out = run.stdout + run.stderr
|
const out = run.stdout + run.stderr
|
||||||
assert.equal(run.status, 1, out)
|
assert.equal(run.status, 1, out)
|
||||||
assert.match(out, /FAIL: explicit superpowers source .* has no using-superpowers\/SKILL\.md/)
|
assert.match(out, /FAIL: explicit superpowers source is invalid: .* has no using-superpowers\/SKILL\.md/)
|
||||||
assert.equal(existsSync(join(home, '.dsh', 'skills', 'brainstorming')), false)
|
assert.equal(existsSync(join(home, '.dsh', 'skills', 'brainstorming')), false)
|
||||||
} finally {
|
} finally {
|
||||||
cleanup(home)
|
cleanup(home)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user