Browse Source

leave comments about failing tests (since Skia upgrade).

master
Craig Oates 5 years ago
parent
commit
d2c0a3bb16
  1. 2
      DeathSocket/ImageServices.fs
  2. 6
      TestCentre/LibraryTests.fs

2
DeathSocket/ImageServices.fs

@ -34,6 +34,7 @@
use bitmap = SKBitmap.Decode (skStream) use bitmap = SKBitmap.Decode (skStream)
(bitmap.Width, bitmap.Height) (bitmap.Width, bitmap.Height)
// Not working since update NuGet to 1.68
let drawSkiaGrid (spec: SkiaSpec) = let drawSkiaGrid (spec: SkiaSpec) =
use fileStream = File.Open (spec.originalPath, FileMode.Open) use fileStream = File.Open (spec.originalPath, FileMode.Open)
use skStream = new SKManagedStream (fileStream) use skStream = new SKManagedStream (fileStream)
@ -75,6 +76,7 @@
let drawSkiaRGBGrid spec = let drawSkiaRGBGrid spec =
use fileStream = File.Open (spec.originalPath, FileMode.Open) use fileStream = File.Open (spec.originalPath, FileMode.Open)
use skStream = new SKManagedStream (fileStream) use skStream = new SKManagedStream (fileStream)
use t = new SKBitmap ()
use bitmap = SKBitmap.Decode (skStream) use bitmap = SKBitmap.Decode (skStream)
use shader = use shader =
SKShader.CreateBitmap (bitmap, SKShaderTileMode.Mirror, SKShaderTileMode.Mirror) SKShader.CreateBitmap (bitmap, SKShaderTileMode.Mirror, SKShaderTileMode.Mirror)

6
TestCentre/LibraryTests.fs

@ -105,14 +105,13 @@
open DeathSocket.GridPainter open DeathSocket.GridPainter
open TestingHelpers open TestingHelpers
open FsCheck.Xunit open FsCheck.Xunit
open SkiaSharp
(* With regards to the "saving images" tests, you should end up with (* With regards to the "saving images" tests, you should end up with
one image left over in the SavingTestArea folder. Comment out the one image left over in the SavingTestArea folder. Comment out the
"reset" function to see all the images produced by this test. This will "reset" function to see all the images produced by this test. This will
mean you will need to manually delete the images yourself if you do. *) mean you will need to manually delete the images yourself if you do. *)
// scaleLineThickness
[<Property>] [<Property>]
let ``Can apply grid to image and save it using BrushSpec`` () = let ``Can apply grid to image and save it using BrushSpec`` () =
resetSavingTestArea () resetSavingTestArea ()
@ -177,6 +176,7 @@
let result = determineVerticalLines (newNum()) (newNum()) (newNum()) let result = determineVerticalLines (newNum()) (newNum()) (newNum())
result.Length > 0 result.Length > 0
// Not working since update NuGet to 1.68
[<Property>] [<Property>]
let ``Can apply grid to image and save it using SkiaSpec`` () = let ``Can apply grid to image and save it using SkiaSpec`` () =
resetSavingTestArea() resetSavingTestArea()
@ -221,8 +221,6 @@
module UnitTests = module UnitTests =
// scaleLineThickness
open TestingHelpers open TestingHelpers
open Xunit open Xunit
open DeathSocket open DeathSocket

Loading…
Cancel
Save