forked from amida-tech/blue-button-xml
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Upgraded dev dependencies * Converted tests and coverages to jest
- Loading branch information
Showing
28 changed files
with
13,698 additions
and
13,445 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"indent_size": 4, | ||
"indent_size": 2, | ||
"indent_char": " ", | ||
"indent_level": 0, | ||
"indent_with_tabs": false, | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,9 @@ | ||
{ | ||
"browser": false, // Standard browser globals e.g. `window`, `document`. | ||
"node": true, // Enable globals available when code is running inside of the NodeJS runtime environment. | ||
"indent": 4, // Specify indentation spacing. | ||
"predef": ["describe", "it"] | ||
"browser": false, // Standard browser globals e.g. `window`, `document`. | ||
"node": true, // Enable globals available when code is running inside of the NodeJS runtime environment. | ||
"indent": 2, // Specify indentation spacing. | ||
"predef": [ | ||
"describe", | ||
"it" | ||
] | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
language: node_js | ||
node_js: | ||
- "6" | ||
- "14.19.1" | ||
|
||
before_script: | ||
- npm install -g [email protected] | ||
- npm install --quiet | ||
- npm install -g mocha | ||
- npm install -g istanbul | ||
- npm install -g [email protected] | ||
- npm install --quiet | ||
|
||
#services: | ||
# - mongodb | ||
|
||
script: | ||
- grunt | ||
- istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec --recursive && cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js && rm -rf ./coverage | ||
- grunt |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,142 +1,84 @@ | ||
/*global module*/ | ||
|
||
module.exports = function (grunt) { | ||
grunt.loadNpmTasks('grunt-contrib-jshint'); | ||
grunt.loadNpmTasks('grunt-mocha-test'); | ||
grunt.loadNpmTasks('grunt-contrib-watch'); | ||
grunt.loadNpmTasks('grunt-coveralls'); | ||
grunt.loadNpmTasks('grunt-jsbeautifier'); | ||
grunt.loadNpmTasks('grunt-browserify'); | ||
grunt.loadNpmTasks('grunt-mocha-phantomjs'); | ||
grunt.loadNpmTasks('grunt-contrib-connect'); | ||
grunt.loadNpmTasks('grunt-contrib-jshint'); | ||
grunt.loadNpmTasks('grunt-contrib-watch'); | ||
grunt.loadNpmTasks('grunt-jsbeautifier'); | ||
grunt.loadNpmTasks('grunt-contrib-connect'); | ||
grunt.loadNpmTasks('grunt-run'); | ||
|
||
// Project configuration. | ||
grunt.initConfig({ | ||
pkg: grunt.file.readJSON('package.json'), | ||
jshint: { | ||
files: ['*.js', './lib/*.js', './browser/lib/*.js', '*.json'], | ||
options: { | ||
browser: true, | ||
smarttabs: true, | ||
curly: true, | ||
eqeqeq: true, | ||
immed: true, | ||
latedef: true, | ||
newcap: true, | ||
noarg: true, | ||
sub: true, | ||
undef: false, | ||
boss: true, | ||
eqnull: true, | ||
node: true, | ||
expr: true, | ||
globals: { | ||
'it': true, | ||
'xit': true, | ||
'describe': true, | ||
'before': true, | ||
'after': true, | ||
'done': true, | ||
'Document': true | ||
} | ||
} | ||
}, | ||
watch: { | ||
all: { | ||
files: ['./lib/*.js', '*.js'], | ||
tasks: ['default'] | ||
} | ||
}, | ||
jsbeautifier: { | ||
beautify: { | ||
src: ['Gruntfile.js', 'lib/*.js', 'test/*.js', '*.js', '*.json', './browser/lib/*.js'], | ||
options: { | ||
config: '.jsbeautifyrc' | ||
} | ||
}, | ||
check: { | ||
src: ['Gruntfile.js', 'lib/*.js', 'test/*.js', '*.js', './browser/lib/*.js'], | ||
options: { | ||
mode: 'VERIFY_ONLY', | ||
config: '.jsbeautifyrc' | ||
} | ||
} | ||
}, | ||
mochaTest: { | ||
test: { | ||
options: { | ||
reporter: 'spec', | ||
timeout: '10000', | ||
recursive: true | ||
}, | ||
src: ['test/*.js'] | ||
} | ||
}, | ||
coveralls: { | ||
options: { | ||
// LCOV coverage file relevant to every target | ||
src: 'coverage/lcov.info', | ||
|
||
// When true, grunt-coveralls will only print a warning rather than | ||
// an error, to prevent CI builds from failing unnecessarily (e.g. if | ||
// coveralls.io is down). Optional, defaults to false. | ||
force: false | ||
}, | ||
//your_target: { | ||
// Target-specific LCOV coverage file | ||
//src: 'coverage-results/extra-results-*.info' | ||
//}, | ||
}, | ||
browserify: { | ||
standalone: { | ||
src: ['<%=pkg.main%>'], | ||
dest: 'dist/<%=pkg.name%>.standalone.js', | ||
options: { | ||
standalone: '<%=pkg.name%>' | ||
} | ||
}, | ||
require: { | ||
src: ['<%=pkg.main%>'], | ||
dest: 'dist/<%=pkg.name%>.js', | ||
options: { | ||
alias: [__dirname + "/index.js:<%=pkg.name%>"] | ||
} | ||
}, | ||
tests: { | ||
src: ['test/**/*.js'], | ||
dest: 'dist/mocha_tests.js', | ||
options: { | ||
transform: ['brfs'] | ||
} | ||
} | ||
}, | ||
connect: { | ||
server: { | ||
options: { | ||
port: 8000, | ||
hostname: '127.0.0.1' | ||
} | ||
} | ||
}, | ||
'mocha_phantomjs': { | ||
all: { | ||
options: { | ||
urls: [ | ||
'http://127.0.0.1:8000/dist/mocha_runner.html' | ||
] | ||
} | ||
} | ||
// Project configuration. | ||
grunt.initConfig({ | ||
pkg: grunt.file.readJSON('package.json'), | ||
jshint: { | ||
files: ['*.js', './lib/*.js', './browser/lib/*.js', '*.json'], | ||
options: { | ||
browser: true, | ||
smarttabs: true, | ||
curly: true, | ||
eqeqeq: true, | ||
immed: true, | ||
latedef: true, | ||
newcap: true, | ||
noarg: true, | ||
sub: true, | ||
undef: false, | ||
boss: true, | ||
eqnull: true, | ||
node: true, | ||
expr: true, | ||
globals: { | ||
'it': true, | ||
'xit': true, | ||
'describe': true, | ||
'before': true, | ||
'after': true, | ||
'done': true, | ||
'Document': true | ||
} | ||
}); | ||
|
||
grunt.registerTask('beautify', ['jsbeautifier:beautify']); | ||
// grunt.registerTask('browser-test', ['browserify:require', 'browserify:tests', 'connect:server', 'mocha_phantomjs']); | ||
grunt.registerTask('mocha', ['mochaTest']); | ||
grunt.registerTask('commit', ['jshint', 'mocha']); | ||
|
||
grunt.registerTask('default', ['beautify', 'jshint', 'mocha' /*, 'browser-test'*/ ]); | ||
} | ||
}, | ||
watch: { | ||
all: { | ||
files: ['./lib/*.js', '*.js'], | ||
tasks: ['default'] | ||
} | ||
}, | ||
jsbeautifier: { | ||
beautify: { | ||
src: ['Gruntfile.js', 'lib/*.js', 'test/*.js', '*.js', '*.json', './browser/lib/*.js'], | ||
options: { | ||
config: '.jsbeautifyrc' | ||
} | ||
}, | ||
check: { | ||
src: ['Gruntfile.js', 'lib/*.js', 'test/*.js', '*.js', './browser/lib/*.js'], | ||
options: { | ||
mode: 'VERIFY_ONLY', | ||
config: '.jsbeautifyrc' | ||
} | ||
} | ||
}, | ||
run: { | ||
jest: { | ||
exec: 'npx jest', | ||
args: ['test'] | ||
} | ||
}, | ||
connect: { | ||
server: { | ||
options: { | ||
port: 8000, | ||
hostname: '127.0.0.1' | ||
} | ||
} | ||
} | ||
}); | ||
|
||
grunt.registerTask('timestamp', function () { | ||
grunt.log.subhead(Date()); | ||
}); | ||
grunt.registerTask('default', ['beautify', 'jshint', 'run']); | ||
grunt.registerTask('beautify', ['jsbeautifier:beautify']); | ||
grunt.registerTask('commit', ['default']); | ||
grunt.registerTask('timestamp', function () { | ||
grunt.log.subhead(Date()); | ||
}); | ||
}; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{ | ||
"name": "blue-button-xml", | ||
"version": "1.8.2", | ||
"main": "dist/blue-button-xml", | ||
"license": "Apache-2.0", | ||
"ignore": ["**/*", "!dist/*", "!bower.json", "!LICENSE"] | ||
"name": "blue-button-xml", | ||
"version": "1.8.2", | ||
"main": "dist/blue-button-xml", | ||
"license": "Apache-2.0", | ||
"ignore": ["**/*", "!dist/*", "!bower.json", "!LICENSE"] | ||
} |
Oops, something went wrong.