Skip to content

Commit 17e601e

Browse files
committed
fixed broken tests
1 parent 93b4a66 commit 17e601e

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
`STEVE` is a configurable template engine that allows JavaScript to run in files to create files. It has a plugin system to allow for custom generation and a built-in site generator.
44

5-
***ST***atic Sit_**E**_ Generator (***VE***ry cool)
5+
***ST***atic Sit***E*** Generator (***VE***ry cool)
66

77
### by AP
88

src/core/steve.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ class STEVE {
243243
_result += _fragment;
244244
}
245245
} catch (err) {
246-
throw new Error(`${err} inside STEVE tags: ${_current.slice(0, -this.tags.end.length)}`)
246+
throw new Error(`${err} inside STEVE tags: ${_current.slice(0, -this.tags.end.length).slice(0, 50)}...`)
247247
}
248248

249249
_current = '';

test/steve.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,9 +181,9 @@ Deno.test('STEVE: nested STEVE tags throw error', () => {
181181
Deno.test('STEVE: error in STEVE tags is caught correctly', () => {
182182
const content = 'Hello, <steve> funcion error </steve>';
183183
const data = {};
184-
184+
185185
assertThrows(
186186
() => STEVE.render(content, data),
187-
TypeError,
187+
Error,
188188
);
189189
})

0 commit comments

Comments
 (0)