Skip to content
This repository was archived by the owner on Apr 20, 2024. It is now read-only.

Conversation

@mustachedkdev
Copy link

I've tried to make a Vapor 4 implementation, the tests are failed for some reason, perhaps someone can help me with it.

@sadiq81

@siemensikkema
Copy link
Contributor

siemensikkema commented Dec 4, 2019

@mustachedkdev Thanks for your PR! The tests can be fixed by updating the .circleci/config.yml file. This should work:

version: 2
jobs:
  MacOS:
    macos:
      xcode: "11.2.1"
    steps:
      - checkout
      - restore_cache:
          keys:
            - v1-spm-deps-{{ checksum "Package.swift" }}
      - run:
          name: Install dependencies
          command: |
            brew tap vapor/homebrew-tap
            brew install cmysql
            brew install ctls
            brew install libressl
            brew install cstack
      - run:
          name: Build and Run Tests
          no_output_timeout: 1800
          command: |
            swift package generate-xcodeproj --enable-code-coverage
            xcodebuild -scheme Gatekeeper-Package -enableCodeCoverage YES test | xcpretty
      - run:
          name: Report coverage to Codecov
          command: |
            bash <(curl -s https://codecov.io/bash)
      - save_cache:
          key: v1-spm-deps-{{ checksum "Package.swift" }}
          paths:
            - .build
  Linux:
    docker:
      - image: nodesvapor/vapor-ci:swift-5.1
    steps:
      - checkout
      - restore_cache:
          keys:
            - v1-spm-deps-{{ checksum "Package.swift" }}
      - run:
          name: Copy Package File
          command: cp Package.swift res
      - run:
          name: Build and Run Tests
          no_output_timeout: 1800
          command: |
            swift test
      - run:
          name: Restoring Package File
          command: mv res Package.swift
      - save_cache:
          key: v1-spm-deps-{{ checksum "Package.swift" }}
          paths:
            - .build
workflows:
  version: 2
  build-and-test:
    jobs:
      - MacOS
      - Linux
experimental:
  notify:
    branches:
      only:
        - master
        - develop

Don't forget to run swift test --generate-linux-main as well. (or remove Tests/LinuxMain.swift and Tests/GateKeeperTests/XCTestManifests.swift and change swift test to swift test --enable-test-discovery in the Linux section above)

@siemensikkema siemensikkema changed the title Upgrade to Vapor Upgrade to Vapor 4 Dec 4, 2019
@namolnad
Copy link

Hey, wanted to check in on this. From an outsiders perspective it looks as though this is close to the finish line. Any updates here?

@siemensikkema
Copy link
Contributor

Closing because this is implemented in #20

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants