Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
chore(deps): upgrade to latest stable
- cleaned up travis.yml. it now runs node 10/12/13.
- cleaner coverage report scripts for each service.
- replaced deprecated instanbul with nyc.
- removed autotest. mocha has its own watcher (npm test -- -w)
  • Loading branch information
Avi Vahl committed Feb 22, 2020
commit 0700f97898a5db1c119928b56f827962f0a8a221
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
node_modules
coverage
.nyc_output
package-lock.json
18 changes: 8 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
sudo: false
language: node_js

node_js:
- "0.10"
- "0.12"
- "iojs"
script: npm run travis
- 10
- 12
- 13

before_install:
- '[ "${TRAVIS_NODE_VERSION}" != "0.10" ] || npm install -g npm'
script: npm run cover

after_success:
- cat ./coverage/lcov.info | node_modules/.bin/coveralls --verbose
- cat ./coverage/coverage.json | node_modules/codecov.io/bin/codecov.io.js
- rm -rf ./coverage
- npm run report:coveralls
- npm run report:codecov

6 changes: 2 additions & 4 deletions lib/stringify.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
"use strict";

var stringify;

var regexpu = require("regexpu-core");
var identifierEscapeRegexp = new RegExp(
regexpu("(^[^A-Za-z_\\-\\u{00a0}-\\u{10ffff}]|^\\-\\-|[^A-Za-z_0-9\\-\\u{00a0}-\\u{10ffff}])", "ug"),
regexpu("(^[^A-Za-z_\\-\\u{00a0}-\\u{10ffff}]|^--|[^A-Za-z_0-9\\-\\u{00a0}-\\u{10ffff}])", "ug"),
"g"
);

Expand Down Expand Up @@ -53,7 +51,7 @@ function stringifyWithoutBeforeAfter(tree) {
}


stringify = function stringify(tree) {
function stringify(tree) {
var str = stringifyWithoutBeforeAfter(tree);
if(tree.before) {
str = tree.before + str;
Expand Down
26 changes: 12 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,12 @@
"description": "Parses and stringifies CSS selectors",
"main": "lib/index.js",
"scripts": {
"lint": "eslint lib",
"lint": "eslint .",
"pretest": "npm run lint",
"test": "mocha",
"autotest": "chokidar lib test -c 'npm test'",
"precover": "npm run lint",
"cover": "istanbul cover node_modules/mocha/bin/_mocha",
"travis": "npm run cover -- --report lcovonly",
"cover": "nyc npm test",
"report:coveralls": "nyc report --reporter=text-lcov | coveralls",
"report:codecov": "nyc report --reporter=text-lcov | codecov --pipe",
"publish-patch": "npm test && npm version patch && git push && git push --tags && npm publish"
},
"repository": {
Expand All @@ -31,17 +30,16 @@
},
"homepage": "https://github.com/css-modules/css-selector-tokenizer",
"dependencies": {
"cssesc": "^0.1.0",
"fastparse": "^1.1.1",
"regexpu-core": "^1.0.0"
"cssesc": "^3.0.0",
"fastparse": "^1.1.2",
"regexpu-core": "^4.6.0"
},
"devDependencies": {
"chokidar-cli": "^0.2.1",
"codecov.io": "^0.1.2",
"coveralls": "^2.11.2",
"eslint": "^0.21.2",
"istanbul": "^0.3.14",
"mocha": "^2.2.5"
"codecov": "^3.6.5",
"coveralls": "^3.0.9",
"eslint": "^6.8.0",
"mocha": "^7.0.1",
"nyc": "^15.0.0"
},
"directories": {
"test": "test"
Expand Down