Skip to content

Commit cb967b0

Browse files
committed
1.2.1
1 parent ab7bb6d commit cb967b0

File tree

3 files changed

+13
-4
lines changed

3 files changed

+13
-4
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changes to PostCSS Tape
22

3+
### 1.2.1 (December 14, 2016)
4+
5+
- Updated: Throw existing error
6+
- Updated: Run `after` even if test fails
7+
38
### 1.2.0 (December 14, 2016)
49

510
- Added: Expected `error` option

index.js

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,10 @@ Promise.all(Object.keys(tests).map(
106106
if (expectedError) {
107107
return ` ${ pass } ${ test.message }`;
108108
} else {
109+
if (test.after) {
110+
test.after();
111+
}
112+
109113
throw error;
110114
}
111115
}
@@ -124,10 +128,10 @@ Promise.all(Object.keys(tests).map(
124128
).then(
125129
(messages) => process.stdout.write(`${ pass } ${ section }\n${ messages.join('\n') }\n`)
126130
).catch(
127-
(error) => {
128-
process.stdout.write(`${ fail } ${ section }\n${ error.message }\n`);
131+
(error) => {
132+
process.stdout.write(`${ fail } ${ section }\n${ error }\n`);
129133

130-
throw Error;
134+
throw error;
131135
}
132136
)
133137
)).then(

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "postcss-tape",
3-
"version": "1.2.0",
3+
"version": "1.2.1",
44
"description": "Quickly test a PostCSS Plugin",
55
"author": "Jonathan Neal <jonathantneal@hotmail.com>",
66
"license": "CC0-1.0",

0 commit comments

Comments
 (0)