From b9129dc15693590bde8057fcc3bb1d2245655f41 Mon Sep 17 00:00:00 2001 From: Toru Nagashima Date: Sun, 16 Jun 2019 20:54:58 +0900 Subject: [PATCH] Chore: CI with Azure Pipelines [skip ci] --- .travis.yml | 18 ------------ README.md | 9 +----- appveyor.yml | 28 ------------------ azure-pipelines.yml | 53 ++++++++++++++++++++++++++++++++++ tests/lib/cli-engine/_utils.js | 5 ++++ 5 files changed, 59 insertions(+), 54 deletions(-) delete mode 100644 .travis.yml delete mode 100644 appveyor.yml create mode 100644 azure-pipelines.yml diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 40aa2a8a47de..000000000000 --- a/.travis.yml +++ /dev/null @@ -1,18 +0,0 @@ -language: node_js -node_js: - - "8" - - "10" - - "11" - - "12" -branches: - only: - - master - -# Run npm test always -script: - - "npm test" -after_success: - - 'if [ "$node_js" = "8" ]; then npm run coveralls; fi' -addons: - code_climate: - repo_token: 1945f7420d920a59f1ff8bf8d1a7b60ccd9e2838a692f73a5a74accd8df30146 diff --git a/README.md b/README.md index 6e5f3db76a65..efc9d7a48d9f 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,5 @@ [![NPM version][npm-image]][npm-url] -[![build status][travis-image]][travis-url] -[![Build status][appveyor-image]][appveyor-url] +[![Build Status](https://dev.azure.com/eslint/eslint/_apis/build/status/eslint.eslint?branchName=master)](https://dev.azure.com/eslint/eslint/_build/latest?definitionId=1&branchName=master) [![Downloads][downloads-image]][downloads-url] [![Bountysource](https://www.bountysource.com/badge/tracker?tracker_id=282608)](https://www.bountysource.com/trackers/282608-eslint?utm_source=282608&utm_medium=shield&utm_campaign=TRACKER_BADGE) [![Join the chat at https://gitter.im/eslint/eslint](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/eslint/eslint?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) @@ -271,11 +270,5 @@ The following companies, organizations, and individuals support ESLint's ongoing [npm-image]: https://img.shields.io/npm/v/eslint.svg?style=flat-square [npm-url]: https://www.npmjs.com/package/eslint -[travis-image]: https://img.shields.io/travis/eslint/eslint/master.svg?style=flat-square -[travis-url]: https://travis-ci.org/eslint/eslint -[appveyor-image]: https://ci.appveyor.com/api/projects/status/iwxmiobcvbw3b0av/branch/master?svg=true -[appveyor-url]: https://ci.appveyor.com/project/nzakas/eslint/branch/master -[coveralls-image]: https://img.shields.io/coveralls/eslint/eslint/master.svg?style=flat-square -[coveralls-url]: https://coveralls.io/r/eslint/eslint?branch=master [downloads-image]: https://img.shields.io/npm/dm/eslint.svg?style=flat-square [downloads-url]: https://www.npmjs.com/package/eslint diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 966263e293f2..000000000000 --- a/appveyor.yml +++ /dev/null @@ -1,28 +0,0 @@ -# AppVeyor file -# http://www.appveyor.com/docs/appveyor-yml - -# Build version format -version: "{build}" - -# What combinations to test -environment: - matrix: - - nodejs_version: 8 - -branches: - only: - - master - -install: - # Get the latest stable version of Node.js - - ps: Install-Product node $env:nodejs_version - # install modules - - npm install - -build: off - -test_script: - - npm test - -matrix: - fast_finish: true # set this flag to immediately finish build once one of the jobs fails. diff --git a/azure-pipelines.yml b/azure-pipelines.yml new file mode 100644 index 000000000000..1f32418f7216 --- /dev/null +++ b/azure-pipelines.yml @@ -0,0 +1,53 @@ +trigger: + - master + +jobs: + - job: tests_on_linux + displayName: Test on Linux + pool: + vmImage: 'Ubuntu-16.04' + strategy: + matrix: + "Node.js 12": + node_version: 12.x + "Node.js 10": + node_version: 10.x + "Node.js 8": + node_version: 8.x + steps: + - task: NodeTool@0 + displayName: Install Node.js + inputs: + versionSpec: $(node_version) + - script: npm install + displayName: Install Packages + - script: npm test + displayName: Test + + - job: tests_on_windows + displayName: Test on Windows + pool: + vmImage: 'Windows-2019' + steps: + - task: NodeTool@0 + displayName: Install Node.js + inputs: + versionSpec: 12.x + - script: npm install + displayName: Install Packages + - script: npm test + displayName: Test + + - job: tests_on_macos + displayName: Test on macOS + pool: + vmImage: 'macOS-10.14' + steps: + - task: NodeTool@0 + displayName: Install Node.js + inputs: + versionSpec: 12.x + - script: npm install + displayName: Install Packages + - script: npm test + displayName: Test diff --git a/tests/lib/cli-engine/_utils.js b/tests/lib/cli-engine/_utils.js index 94d6c0158d2c..1928c9bef298 100644 --- a/tests/lib/cli-engine/_utils.js +++ b/tests/lib/cli-engine/_utils.js @@ -293,6 +293,11 @@ function defineConfigArrayFactoryWithInMemoryFileSystem({ platform: process.platform === "win32" ? "win32" : "posix" }); + // Support D: drive. + if (process.platform === "win32") { + fs._roots.set("D:", fs._makeDir(0o777)); // eslint-disable-line no-underscore-dangle + } + supportMkdirRecursiveOption(fs, cwd); fs.mkdirSync(cwd(), { recursive: true });