Skip to content
lukevmorris edited this page Dec 12, 2017 · 7 revisions

Verify behavior and test for regressions

Prior to publishing your new dygraphs version, you should test it locally. There are two repositories that will help you verify dygraphs' behavior and test for regressions:

  • dygraphs-es6 can be a help when running a manual smoke test.
git clone git@github.com:danvk/dygraphs-es6.git
cd dygraphs-es6
npm install
npm install path/to/dygraphs/directory
./node_modules/.bin/webpack
open index.html

When the page loads, you should see a graph rendered on the screen.

  • dygraphs-dpxdt can be a help when checking for regressions. This project runs a series of tests and captures screenshots for each test case.

Bump version strings and add release notes

Note: During this process, you may notice some untracked files (e.g. in /src-es5). Be sure not to include and commit these files when you run through the following process.

git checkout master
git pull
# add a new section in releases.json
# update version in package.json
# update version in dygraph.js
# add a new section in docs/versions.html, including major changelog entries
git commit -a -m 'Bump versions and add release notes'
git push

Draft a GitHub Release

Navigate to the releases page of the dygraphs repository and draft a new release. Take the version string that you've committed in the files above, and use the formatted version (with a v in front, e.g. v2.1.0) for both the Tag version and the Release title. Use the description section to write a summary of the changes in this release, including New features, Bug fixes, Internal refactors/fixes, etc. Feel free to use the description markdown from a previous release as a guide. When finished, press Publish release. Keep in mind that you can make changes to this release later if there are mistakes to correct.

Publish NPM Package

Note: When pushing code to GitHub, we intentionally exclude files that are generated during an npm run build, as it can be a pain to keep these files in sync without merge conflicts. However, we do want these files to be present while we publish a new build to NPM. If they are missing at the time of a publish, NPM will receive an incomplete package, and you will have to bump the version string again to publish again.

git checkout master
git pull
npm install
npm run build

# Verify the presence of the `dist/` and `src-es5/` directories.
ls

npm publish

Verification

  • Verify that the NPM listing has the newest release.

  • Use the dygraphs-es6 project mentioned above to validate your new build. Install your new dygraphs version (e.g. 2.1.0) and open index.html:

cd dygraphs-es6
npm install dygraphs@2.1.0
./node_modules/.bin/webpack
open index.html
  • Verify that cdnjs has picked up the change. This might take up to ~15min.

Update dygraphs.com

Notify Dygraphs Users

Clone this wiki locally