This repository has been archived by the owner on Mar 8, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 197
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* HARP-14470 code coverage moved to karma - nyc only supports code coverage in node, however we have a number of browser based tests, and it is the primary use case, so we have decided to do the code coverage in karma. - the karma.conf.js previously used the pre-bundled test bundle, but this doesn't give us the code coverage per line number, I could have tried to find a way to remap the bundle to lines, but because the karma-typescript project is well maintained, I went this road. This however means there is a lot of configuration to get the tests running correctly, especially those that need to load resources. - note also, there are quite a few tests that time out when run in the browser, hence the need to change the timeout in some cases - note also, karma outputs the code coverage format using lcov, this is different to nyc and means that the code coverage drops a lot, this is because the lcov format can tell if a line is fully covered, i.e. for an if statement, it records if both true and false variants are executed. As such, lines without full branch coverage are treated as not covered, and this reduces the code coverage in the codecov.io report available via github. The local text report which is shown when running `yarn cov-test` doesn't have this behaviour, i.e lines that have just one branch executed are counted as part of the code coverage. Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Change to `coverage` directory Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Fixes when coresdk is installed next to sdk Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Move karma.conf.js to karma.options.js so sdk can import and extend the configuration Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Fix prefixes for the exclude files Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Change script to match sdk, i.e `test-cov` Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Change reporter to use the same as nyc so that the numbers are better to compare Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Remove redundant test files Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Add comment to ticket to refactor code Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Removing incorrect comments Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Readd test script Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Exclude code coverage for vector_tile.js, I think it is from MapBox, anything ending with node.ts or index*.ts, or anything which is in a test/ directory Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 HARP-15326 Don't include react components Signed-off-by: Jonathan Stichbury <[email protected]> * HARP-14470 Remove test utils for IBCT Signed-off-by: Jonathan Stichbury <[email protected]>
- Loading branch information
Showing
29 changed files
with
1,011 additions
and
165 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.