We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not sure if this is the right place to file this issue but your project seems to me to be a common denominator.
My goal is to get code coverage reports of a typescript project. Therefore I use the karma test runner in the following configuration.
var istanbul = require('browserify-istanbul'); module.exports = function(config) { config.set({ basePath: '', frameworks: ['browserify', 'mocha', 'chai', 'source-map-support'], files: [ 'test/**/*Spec.ts' ], exclude: [ ], preprocessors: { 'test/**/*Spec.ts': ['browserify'] }, browserify: { debug: true, transform: [istanbul()] }, reporters: ['progress', 'coverage'], port: 9876, colors: true, logLevel: config.LOG_INFO, autoWatch: true, browsers: ['Chrome'], singleRun: true, concurrency: Infinity }) }
export function add(a: number, b: number): number { if (a === 0) return b if (b === 0) return a return a + b }
import {add} from '../src/add' const expect = chai.expect describe('test add module', () => { it('should add 2 numbers', () => { expect(add(1, 2)).to.be.equal(3) }) })
The metrics of the coverage report seem to be ok but the annotation in the "source file view" are a bit odd.
My first guess is that something with the source maps went wrong due to the multiple transformations along the process.
I hope you can provide me any information or point me in the right direction to solve this issue.
Also I filed this as a question on stackoverflow earlier today: http://stackoverflow.com/questions/38764929/how-to-do-code-coverage-with-karma-typescript-and-browserify
The text was updated successfully, but these errors were encountered:
Closing this as WONT_FIX as this is I don't have sufficient knowledge on tsify + coverage setups to help you out on this one.
WONT_FIX
tsify
Sorry, something went wrong.
No branches or pull requests
Not sure if this is the right place to file this issue but your project seems to me to be a common denominator.
My goal is to get code coverage reports of a typescript project. Therefore I use the karma test runner in the following configuration.
src/add.ts
test/addSpec.ts
The metrics of the coverage report seem to be ok but the annotation in the "source file view" are a bit odd.
My first guess is that something with the source maps went wrong due to the multiple transformations along the process.
I hope you can provide me any information or point me in the right direction to solve this issue.
Also I filed this as a question on stackoverflow earlier today: http://stackoverflow.com/questions/38764929/how-to-do-code-coverage-with-karma-typescript-and-browserify
The text was updated successfully, but these errors were encountered: