From c8debdbb0b25eab775f9ac9d1ad183448782d80d Mon Sep 17 00:00:00 2001 From: Alex Evgrashin Date: Sat, 15 Feb 2020 19:01:14 +0300 Subject: [PATCH] More testing --- .github/workflows/main.yml | 238 ----------------------------- .github/workflows/reporterTest.yml | 2 +- 2 files changed, 1 insertion(+), 239 deletions(-) delete mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml deleted file mode 100644 index 0217acc..0000000 --- a/.github/workflows/main.yml +++ /dev/null @@ -1,238 +0,0 @@ -name: Actions ๐Ÿ˜Ž -on: - pull_request: {} - push: { branches: [master] } - -env: - UNITY_LICENSE: "\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \nJHdOBFmBNq2H8BrGFzir/StLoYo=aENLHd37a51RtP2/g7YU0Pexf5mx0/ENXYGtrPzqwZ8NQt2AsSdxGnl0CUB45/GuNXfJVDt2HWot\ncNYZB2OylVBn1WHQbKZlPmm8gEAMz0MYbr4Isb5i5buryBrZlmbEOjnRI+pEg1CBwlgMo6xdtjjE\n/d7cC293QIUO91kdzRXftYou1dNaUyuPL9ZH65vdB2pDXGRNxgUVD+GnnqZA7b5L2HXqNQclcWAK\n5Yd1BeF3VzR1iLw9G/SmH5oOhnpXSmqbL4qk7LVP2/mgXpFk5kP4X8VC3z47obNhBIGq40dwWyEe\nUYk5/nRAOkZawDT+tcu96e06gPC9Cxk5PdbRbA==" - -jobs: - tests: - name: Tests - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1.1.2 - with: - node-version: 12.x - - run: yarn - - run: yarn lint - - run: yarn test - - run: yarn build || { echo "build command should always succeed" ; exit 61; } - - run: yarn build --quiet && git diff --quiet action || { echo "action should be auto generated" ; exit 62; } - - testAllModesLikeInTheReadme: - name: Test in ${{ matrix.testMode }} on version ${{ matrix.unityVersion }} - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - projectPath: - - unity-project-with-correct-tests - unityVersion: - - 2019.2.11f1 - testMode: - - playmode - - editmode - steps: - - uses: actions/checkout@v2 - with: - lfs: true - - uses: actions/cache@v1.1.0 - with: - path: ${{ matrix.projectPath }}/Library - key: Library-${{ matrix.projectPath }} - restore-keys: | - Library- - - uses: ./ - id: tests - with: - projectPath: ${{ matrix.projectPath }} - unityVersion: ${{ matrix.unityVersion }} - testMode: ${{ matrix.testMode }} - artifactsPath: ${{ matrix.testMode }}-artifacts - customParameters: -profile SomeProfile -someBoolean -someValue exampleValue - - uses: actions/upload-artifact@v1 - with: - name: Test results for ${{ matrix.testMode }} - path: ${{ steps.tests.outputs.artifactsPath }} - - testRunnerInAllModes: - name: Test all modes โœจ - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - projectPath: - - unity-project-with-correct-tests - unityVersion: - - 2019.2.11f1 - steps: - # Checkout repository (required to test local actions) - - name: Checkout repository - uses: actions/checkout@v2 - with: - lfs: true - - # Enable caching - - uses: actions/cache@v1.1.0 - with: - path: ${{ matrix.projectPath }}/Library - key: Library-${{ matrix.projectPath }}-${{ matrix.targetPlatform }} - restore-keys: | - Library-${{ matrix.projectPath }}- - Library- - - # Configure test runner - - name: Run tests - id: allTests - uses: ./ - with: - projectPath: ${{ matrix.projectPath }} - unityVersion: ${{ matrix.unityVersion }} - testMode: all - # Test implicit artifactsPath, by not setting it - - # Upload artifacts - - name: Upload test results - uses: actions/upload-artifact@v1 - with: - name: Test results (all) - path: ${{ steps.allTests.outputs.artifactsPath }} - - testRunnerInEditMode: - name: Test edit mode ๐Ÿ“ - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - unityVersion: - - 2019.2.11f1 - projectPath: - - unity-project-with-correct-tests - steps: - # Checkout repository (required to test local actions) - - name: Checkout repository - uses: actions/checkout@v2 - with: - lfs: true - - # Enable caching - - uses: actions/cache@v1.1.0 - with: - path: ${{ matrix.projectPath }}/Library - key: Library-${{ matrix.projectPath }}-${{ matrix.targetPlatform }} - restore-keys: | - Library-${{ matrix.projectPath }}- - Library- - - # Configure test runner - - name: Run tests - id: editMode - uses: ./ - with: - projectPath: ${{ matrix.projectPath }} - unityVersion: ${{ matrix.unityVersion }} - testMode: editmode - artifactsPath: artifacts/editmode - - # Upload artifacts - - name: Upload test results - uses: actions/upload-artifact@v1 - with: - name: Test results (edit mode) - path: ${{ steps.editMode.outputs.artifactsPath }} - - testRunnerInPlayMode: - name: Test play mode ๐Ÿ“บ - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - projectPath: - - unity-project-with-correct-tests - unityVersion: - - 2019.2.11f1 - steps: - # Checkout repository (required to test local actions) - - name: Checkout repository - uses: actions/checkout@v2 - with: - lfs: true - - # Enable caching - - uses: actions/cache@v1.1.0 - with: - path: ${{ matrix.projectPath }}/Library - key: Library-${{ matrix.projectPath }}-${{ matrix.targetPlatform }} - restore-keys: | - Library-${{ matrix.projectPath }}- - Library- - - # Configure test runner - - name: Run tests - id: playMode - uses: ./ - with: - projectPath: ${{ matrix.projectPath }} - unityVersion: ${{ matrix.unityVersion }} - testMode: playmode - artifactsPath: artifacts/playmode - - # Upload artifacts - - name: Upload test results - uses: actions/upload-artifact@v1 - with: - name: Test results (play mode) - path: ${{ steps.playMode.outputs.artifactsPath }} - - testEachModeSequentially: - name: Test each mode sequentially ๐Ÿ‘ฉโ€๐Ÿ‘ฉโ€๐Ÿ‘งโ€๐Ÿ‘ฆ # don't try this at home (it's much slower) - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - unityVersion: - - 2019.2.11f1 - projectPath: - - unity-project-with-correct-tests - steps: - # Checkout repository (required to test local actions) - - name: Checkout repository - uses: actions/checkout@v2 - with: - lfs: true - - # Enable caching - - uses: actions/cache@v1.1.0 - with: - path: ${{ matrix.projectPath }}/Library - key: Library-${{ matrix.projectPath }}-${{ matrix.targetPlatform }} - restore-keys: | - Library-${{ matrix.projectPath }}- - Library- - - # Configure first test runner - - name: Tests in editmode ๐Ÿ“ - uses: ./ - with: - projectPath: ${{ matrix.projectPath }} - unityVersion: ${{ matrix.unityVersion }} - testMode: editmode - artifactsPath: artifacts/editmode - - # Configure second test runner - - name: Tests in playmode ๐Ÿ“บ - uses: ./ - with: - projectPath: ${{ matrix.projectPath }} - unityVersion: ${{ matrix.unityVersion }} - testMode: playmode - artifactsPath: artifacts/playmode - - # Upload combined artifacts - - name: Upload combined test results - uses: actions/upload-artifact@v1 - with: - name: Test results (combined) - path: artifacts/ diff --git a/.github/workflows/reporterTest.yml b/.github/workflows/reporterTest.yml index ea62f71..de976c5 100644 --- a/.github/workflows/reporterTest.yml +++ b/.github/workflows/reporterTest.yml @@ -57,4 +57,4 @@ jobs: uses: actions/setup-dotnet@v1 with: dotnet-version: '2.1.202' - - run: dotnet ./UnityTestRunnerResultsReporter/UnityTestRunnerResultsReporter.dll \ No newline at end of file + - run: dotnet ./UnityTestRunnerResultsReporter/UnityTestRunnerResultsReporter.dll \ No newline at end of file