Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
The fixtures now provide a sourceFile property which can be used to get the
source location.
  • Loading branch information
novemberborn committed Dec 7, 2015
1 parent 50ef95d commit eeaa1dd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
"devDependencies": {
"chai": "^3.0.0",
"sinon": "^1.15.3",
"source-map-fixtures": "^0.1.0",
"source-map-fixtures": "^0.2.0",
"standard": "^5.2.1",
"tap": "^1.3.4"
},
Expand Down
2 changes: 1 addition & 1 deletion test/source-map-cache.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ var fixture = require('source-map-fixtures').inline('branching')
// compute the path to the fixture file relative to the root directory.
var relpath = './' + path.relative(path.join(__dirname, '..'), fixture.file)
// the sourcemap itself remaps the path.
var mappedPath = './' + path.join(path.dirname(relpath), '../src/branching.js')
var mappedPath = './' + path.relative(path.join(__dirname, '..'), fixture.sourceFile)
// Compute the number of lines in the original source, excluding any line break
// at the end of the file.
var maxLine = fixture.sourceContentSync().trimRight().split(/\r?\n/).length
Expand Down

0 comments on commit eeaa1dd

Please sign in to comment.