version: 2.1

orbs:
  node: circleci/node@4.1.0

jobs:
  test:
    parameters:
      node_version:
        type: string
    executor:
      name: node/default
      tag: << parameters.node_version >>
    steps:
      - checkout
      - node/install-packages
      - run:
          name: Install CodeClimate test reporter
          command: |
            curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
            chmod +x ./cc-test-reporter
            ./cc-test-reporter before-build
      - run:
          name: Run test tasks
          command: npm test
      - run:
          name: Upload coverage report to CodeClimate
          command: ./cc-test-reporter after-build

workflows:
  version: 2
  default:
    jobs:
      - test:
          matrix:
            parameters:
              node_version:
                - "10.23-browsers"
                - "12.20-browsers"
                - "14.15-browsers"
                - "15.6-browsers"

version: 2.1

orbs:
  node: circleci/node@4.1.0

workflows:
  version: 2
  default:
    jobs:
      - node/test:
          matrix:
            parameters:
              version:
                - "10.23-browsers"
                - "12.20-browsers"
                - "14.15-browsers"
                - "15.6-browsers"

Use built-in orb matrix testing
Use built-in orb matrix testing
