ava 4.3.0 → 4.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -220,6 +220,9 @@ export default class Reporter {
220
220
  this.lineNumberErrors.push(event);
221
221
 
222
222
  this.write(colors.information(`${figures.warning} Could not parse ${this.relativeFile(event.testFile)} for line number selection`));
223
+ this.lineWriter.writeLine();
224
+ this.lineWriter.writeLine(colors.errorStack(event.err.stack));
225
+ this.lineWriter.writeLine();
223
226
  break;
224
227
  }
225
228
 
@@ -66,6 +66,13 @@ const translate = (sourceMap, pos) => {
66
66
  }
67
67
 
68
68
  const entry = sourceMap.findEntry(pos.line - 1, pos.column); // Source maps are 0-based
69
+
70
+ // When used with ts-node/register, we've seen entries without original values. Return the
71
+ // original position.
72
+ if (entry.originalLine === undefined || entry.originalColumn === undefined) {
73
+ return pos;
74
+ }
75
+
69
76
  return {
70
77
  line: entry.originalLine + 1, // Readjust for Acorn.
71
78
  column: entry.originalColumn,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ava",
3
- "version": "4.3.0",
3
+ "version": "4.3.1",
4
4
  "description": "Node.js test runner that lets you develop with confidence.",
5
5
  "license": "MIT",
6
6
  "repository": "avajs/ava",
package/readme.md CHANGED
@@ -66,6 +66,8 @@ Alternatively you can install `ava` manually:
66
66
  npm install --save-dev ava
67
67
  ```
68
68
 
69
+ *Make sure to install AVA locally. As of AVA 4 it can no longer be run globally.*
70
+
69
71
  Don't forget to configure the `test` script in your `package.json` as per above.
70
72
 
71
73
  ### Create your test file