Browse Source

update ci run

ell 1 year ago
parent
commit
137126656a
3 changed files with 9 additions and 48 deletions
  1. 6 3
      .github/workflows/main.yml
  2. 2 2
      testing/tests/audio.lua
  3. 1 43
      testing/tests/graphics.lua

+ 6 - 3
.github/workflows/main.yml

@@ -70,7 +70,7 @@ jobs:
         echo "OPENBOXPID=$!" >> $GITHUB_ENV
     # linux opengl tests
     - name: Run All Tests (opengl)
-      run: xvfb-run ./love-${{ github.sha }}.AppImage ./testing/main.lua
+      run: ./love-${{ github.sha }}.AppImage ./testing/main.lua
     - name: Love Test Report (opengl)
       uses: ellraiser/love-test-report@main
       with:
@@ -89,7 +89,7 @@ jobs:
     - name: Run Test Suite (opengles)
       run: |
         export LOVE_GRAPHICS_USE_OPENGLES=1
-        xvfb-run ./love-${{ github.sha }}.AppImage ./testing/main.lua
+        ./love-${{ github.sha }}.AppImage ./testing/main.lua
     - name: Love Test Report (opengles)
       uses: ellraiser/love-test-report@main
       with:
@@ -108,7 +108,7 @@ jobs:
     - name: Run Test Suite (vulkan)
       run: |
         export LOVE_GRAPHICS_DEBUG=1
-        xvfb-run ./love-${{ github.sha }}.AppImage ./testing/main.lua --runAllTests --renderers vulkan
+        ./love-${{ github.sha }}.AppImage ./testing/main.lua --runAllTests --renderers vulkan
     - name: Love Test Report (vulkan)
       uses: ellraiser/love-test-report@main
       with:
@@ -297,9 +297,12 @@ jobs:
     - name: Build Test Exe
       if: steps.vars.outputs.arch != 'ARM64'
       run: cmake --build build --config Release --target install
+    - name: Checkout
+      uses: actions/checkout@v3
     - name: Run Tests (opengl)
       if: steps.vars.outputs.arch != 'ARM64'
       run: |
+        echo 'check dir'
         dir
         powershell.exe ./install/lovec.exe ./testing/main.lua
     # windows opengl test

+ 2 - 2
testing/tests/audio.lua

@@ -29,14 +29,14 @@ love.test.audio.RecordingDevice = function(test)
   -- start recording for a short time
   -- @TODO needs delay for VMs
   local startrecording = device:start(32000, 4000, 16, 1)
-  test:waitFrames(120)
+  test:waitFrames(10)
   test:assertEquals(true, startrecording, 'check recording started')
   test:assertEquals(true, device:isRecording(), 'check now recording')
   test:assertEquals(4000, device:getSampleRate(), 'check sample rate set')
   test:assertEquals(16, device:getBitDepth(), 'check bit depth set')
   test:assertEquals(1, device:getChannelCount(), 'check channel count set')
   local recording = device:stop()
-  test:waitFrames(120)
+  test:waitFrames(10)
   -- after recording 
   test:assertEquals(false, device:isRecording(), 'check not recording')
   test:assertEquals(nil, device:getData(), 'using stop should clear buffer')

+ 1 - 43
testing/tests/graphics.lua

@@ -10,49 +10,7 @@
 
 -- Canvas (love.graphics.newCanvas)
 love.test.graphics.Canvas = function(test)
-  -- create canvas
-  local canvas = love.graphics.newCanvas(32, 32, {
-
-  })
-  test:assertObject(canvas)
-  -- check basic properties
-  test:assertNotNil(canvas:getMSAA())
-  test:assertEquals('none', canvas:getMipmapMode(), 'check default mipmap')
-  --[[
-
-    Texture:getDPIScale check not nil
-    Texture:getDepth check >= 0
-    Texture:getDimensions	w, h 
-
-    Texture:getFormat (list of vals)
-    Texture:getHeight h
-    Texture:getLayerCount >= 0
-    Texture:getMipmapCount >= 1
-    Texture:getPixelDimensions w, h + dpi
-    Texture:getPixelHeight h + dpi
-    Texture:getPixelWidth w + dpi
-    Texture:getTextureType teture types (4 types)
-    Texture:getWidth w
-    Texture:isReadable true unless stencil/depth pixel formats 
-
-    Texture:getWrap
-    Texture:setWrap horiz, vert, depth
-
-    Texture:getDepthSampleMode
-    Texture:setDepthSampleMode compare (list of vals)
-
-    Texture:getFilter
-    Texture:setFilter min, mag, anisotrop
-
-    Texture:getMipmapFilter
-    Texture:setMipmapFilter mode, sharpness
-  ]]
-  -- check rendering
-  canvas:renderTo(function()
-  
-  end)
-  local data = love.graphics.readbackTexture(canvas, {16, 0, 0, 0, 16, 16})
-  -- check some pixels
+  test:skipTest('test class needs writing')
 end