bionode-bwa
Advanced tools
Comparing version 0.0.4 to 0.0.5
{ | ||
"name": "bionode-bwa", | ||
"description": "A Node.js wrapper for the Burrow-Wheeler Aligner (BWA).", | ||
"version": "0.0.4", | ||
"version": "0.0.5", | ||
"homepage": "http://github.com/bionode/bionode-bwa", | ||
@@ -51,6 +51,6 @@ "repository": { | ||
"build-docs": "docco ./lib/bionode-bwa.js", | ||
"coverage": "istanbul cover ./node_modules/.bin/_mocha --report lcovonly -- -R spec && rm -rf ./coverage; rm test/reference.*; rm test/reads.*; rm test/alignment.sam", | ||
"coveralls": "istanbul cover ./node_modules/.bin/_mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info | ./node_modules/.bin/coveralls && rm -rf ./coverage; rm test/reference.*; rm test/reads.*; rm test/alignment.sam" | ||
"coverage": "istanbul cover test/bionode-bwa.js --report lcovonly -- | tap-spec && rm -rf ./coverage; rm test/reference.*; rm test/reads.*; rm test/alignment.sam", | ||
"coveralls": "istanbul cover test/bionode-bwa.js --report lcovonly -- | tap-spec && cat ./coverage/lcov.info | ./node_modules/.bin/coveralls && rm -rf ./coverage; rm test/reference.*; rm test/reads.*; rm test/alignment.sam" | ||
}, | ||
"license": "MIT" | ||
} |
@@ -52,10 +52,11 @@ var bwa = require('../') | ||
if (['index', 'aln'].indexOf(data.operation) === -1 && data.status === 'finished') { | ||
var alignmentFile = fs.createReadStream(data.sam) | ||
var shasum = crypto.createHash('sha1') | ||
alignmentFile.on('data', function(d) { shasum.update(d) }) | ||
alignmentFile.on('end', function() { | ||
var sha1 = shasum.digest('hex'); | ||
t.equal(sha1, hash, msg) | ||
}) | ||
t.ok(fs.statSync(data.sam).size > 5500000, "check that it aligned something") | ||
// var alignmentFile = fs.createReadStream(data.sam) | ||
// var shasum = crypto.createHash('sha1') | ||
// alignmentFile.on('data', function(d) { shasum.update(d) }) | ||
// alignmentFile.on('end', function() { | ||
// var sha1 = shasum.digest('hex'); | ||
// t.equal(sha1, hash, msg) | ||
// }) | ||
} | ||
} |
401454
1016