Skip to content
master
Switch branches/tags
Code

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Codecov VSCode Extension Example

codecov Build Status FOSSA Status

tl;dr

  1. Clone this repo git clone git@github.com:codecov/example-typescript-vscode-extension.git
  2. Start working on your TypeScript project (only ts-code)

Guide

Travis Setup

Add to your .travis.yml file.

language: node

before_install:
  - if [ $TRAVIS_OS_NAME == "linux" ]; then
      export CXX="g++-4.9" CC="gcc-4.9" DISPLAY=:99.0;
      sh -e /etc/init.d/xvfb start;
      sleep 3;
    fi

script:
  - npm run vscode:prepublish
  - npm test

after_success:
- bash <(curl -s https://codecov.io/bash)

Producing Coverage Reports

Make sure you build your extension. In this case via tsc -p ./ or simply npm run vscode:prepublish

Add to coverconfig.json:

{
    "enabled": true,
    "relativeSourcePath": "../src",
    "relativeCoverageDir": "../../coverage",
    "ignorePatterns": ["**/node_modules/**"],
    "includePid": false,
    "reports": ["json", "html", "lcov"],
    "verbose": false
}

Run npm test which runs node ./node_modules/vscode/bin/test

Differences to standard yo code generated example

  • Modified test/index.ts - the main testrunner rewritten completely
  • Changes in stripts and devDependencies section in package.json
  • coverconfig.json added - small config file to change coverage settings localy.

Caveats

Private Repos

Add to your .travis.yml file.

after_success:
  - bash <(curl -s https://codecov.io/bash) -t uuid-repo-token
  1. More documentation at https://docs.codecov.io
  2. Configure codecov through the codecov.yml https://docs.codecov.io/docs/codecov-yaml

We are happy to help if you have any questions. Please contact email our Support at support@codecov.io

License

FOSSA Status

About

No description, website, or topics provided.

Resources

License

Releases

No releases published

Packages

No packages published