Skip to content

Commit

Permalink
[CD/CI] Add GitHub Actions to run tests and publish new package versi…
Browse files Browse the repository at this point in the history
…ons to npm (#683)

Add GitHub Actions to:
1. Run tests for every PR and every commit to `master`.
2. Publish a new package version to npm every time we create a new release.

Additionally, updated the gulp test scripts in the following way:
* `gulp test:integration` does not run unit tests anymore, just the integration tests.
* `gulp test` now runs integration tests in addition to the unit and browser tests it was already running before.
* Browser tests now run in FirefoxHeadless and ChromeHedless because the Firefox browser we used in travis won't work for GH Actions.

* Missing a workflow to update gh-pages when we release a new version.
  • Loading branch information
marcelosalloum authored and Shaptic committed Sep 16, 2021
1 parent 79b218f commit bc43bd1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,6 @@ gulp.task(
gulp.series('build:node', 'test:init-istanbul', function testIntegration() {
return gulp
.src([
'test/test-nodejs.js',
'test/unit/**/*.js',
'test/integration/**/*.js'
])
.pipe(
Expand All @@ -179,7 +177,7 @@ gulp.task('build', gulp.series('clean', 'build:node', 'build:browser'));

gulp.task(
'test',
gulp.series('clean', 'test:unit', 'test:browser', function test(done) {
gulp.series('clean', 'test:unit', 'test:browser', 'test:integration', function test(done) {
done();
})
);
Expand Down
2 changes: 1 addition & 1 deletion karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ delete webpackConfig.output;
module.exports = function(config) {
config.set({
frameworks: ["mocha", "chai-as-promised", "chai", "sinon"],
browsers: ["Firefox"],
browsers: ["FirefoxHeadless", "ChromeHeadless"],

files: [
"dist/stellar-sdk.js",
Expand Down

0 comments on commit bc43bd1

Please sign in to comment.