diff --git a/.circleci/config.yml b/.circleci/config.yml
deleted file mode 100644
index 10d9b82..0000000
--- a/.circleci/config.yml
+++ /dev/null
@@ -1,41 +0,0 @@
-# Javascript Node CircleCI 2.0 configuration file
-#
-# Check https://circleci.com/docs/2.0/language-javascript/ for more details
-#
-version: 2
-jobs:
- build:
- docker:
- # specify the version you desire here
- - image: circleci/node:lts
-
- # Specify service dependencies here if necessary
- # CircleCI maintains a library of pre-built images
- # documented at https://circleci.com/docs/2.0/circleci-images/
- # - image: circleci/mongo:3.4.4
-
- working_directory: ~/repo
-
- steps:
- - checkout
-
- - run: sudo apt install build-essential libcairo2-dev libpango1.0-dev libjpeg-dev libgif-dev librsvg2-dev
-
- # Download and cache dependencies
- - restore_cache:
- keys:
- - v1-dependencies-{{ checksum "package.json" }}
- # fallback to using the latest cache if no exact match is found
- - v1-dependencies-
-
- - run: npm i
-
- - save_cache:
- paths:
- - node_modules
- key: v1-dependencies-{{ checksum "package.json" }}
-
- # run tests!
- - run: npm test
-
-
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
new file mode 100644
index 0000000..d3ccc27
--- /dev/null
+++ b/.github/workflows/ci.yml
@@ -0,0 +1,45 @@
+name: CI/Tests
+
+on:
+ push:
+ branches:
+ - master
+ tags-ignore:
+ - '**'
+ # 忽略以下文件
+ paths-ignore:
+ - '**/*.md'
+ - 'LICENSE'
+ - '**/*.gitignore'
+ - '.editorconfig'
+ - 'docs/**'
+ - 'example/*.png'
+
+ pull_request: null
+
+jobs:
+ test:
+ name: Node ${{ matrix.node }} on ${{ matrix.os }}
+ runs-on: ${{ matrix.os }}
+
+ strategy:
+ fail-fast: false
+ matrix:
+ os: [windows-latest, ubuntu-latest]
+ node: [12, 14, 16]
+
+ steps:
+ - name: Clone repository
+ uses: actions/checkout@v3
+
+ - name: Set up Node.js
+ uses: actions/setup-node@v3
+ with:
+ node-version: ${{ matrix.node }}
+ cache: npm
+
+ - name: Install npm dependencies
+ run: npm ci
+
+ - name: Run tests
+ run: npm test
diff --git a/package.json b/package.json
index efbca99..45de9a5 100644
--- a/package.json
+++ b/package.json
@@ -13,7 +13,7 @@
"index.js"
],
"scripts": {
- "test": "mocha test/specs.js"
+ "test": "mocha test/specs.js --timeout 5000"
},
"devDependencies": {
"expect.js": "^0.3.1",
diff --git a/test/ph.svg b/test/ph.svg
index 2bec5d5..8e482b6 100644
--- a/test/ph.svg
+++ b/test/ph.svg
@@ -6,7 +6,6 @@ viewBox="0 0 0.501891 0.645601"
xmlns:xlink="http://www.w3.org/1999/xlink">
-
-
-