mirror of
https://github.com/Smaug123/unofficial-nunit-runner
synced 2025-10-09 02:58:41 +00:00
Compare commits
2 Commits
WoofWare.N
...
WoofWare.N
Author | SHA1 | Date | |
---|---|---|---|
|
3866823ccd | ||
|
b600fab887 |
1
.github/workflows/dotnet.yaml
vendored
1
.github/workflows/dotnet.yaml
vendored
@@ -74,6 +74,7 @@ jobs:
|
|||||||
run: 'nix develop --command dotnet exec ./TestRunner/bin/Release/net8.0/TestRunner.dll ./Consumer/bin/Release/net8.0/Consumer.dll --trx TrxOut/out.trx'
|
run: 'nix develop --command dotnet exec ./TestRunner/bin/Release/net8.0/TestRunner.dll ./Consumer/bin/Release/net8.0/Consumer.dll --trx TrxOut/out.trx'
|
||||||
- name: Parse Trx files
|
- name: Parse Trx files
|
||||||
uses: NasAmin/trx-parser@v0.6.0
|
uses: NasAmin/trx-parser@v0.6.0
|
||||||
|
if: always()
|
||||||
id: trx-parser
|
id: trx-parser
|
||||||
with:
|
with:
|
||||||
TRX_PATH: ${{ github.workspace }}/TrxOut
|
TRX_PATH: ${{ github.workspace }}/TrxOut
|
||||||
|
@@ -25,10 +25,15 @@ module TestCaseData =
|
|||||||
let ``Consume test data from multiple sources`` (i : int, s : string, arr : float[]) =
|
let ``Consume test data from multiple sources`` (i : int, s : string, arr : float[]) =
|
||||||
lock multipleSources (fun () -> multipleSources.Add (i, s, arr))
|
lock multipleSources (fun () -> multipleSources.Add (i, s, arr))
|
||||||
|
|
||||||
let optional = [ Some "hi" ; None ] |> List.map TestCaseData
|
let optionalData = [ Some "hi" ; None ] |> List.map TestCaseData
|
||||||
|
|
||||||
[<TestCaseSource(nameof optional)>]
|
[<TestCaseSource(nameof optionalData)>]
|
||||||
let ``Consume options`` (s : string option) : unit = s |> shouldEqual s
|
let ``Consume options, TestCaseData`` (s : string option) : unit = s |> shouldEqual s
|
||||||
|
|
||||||
|
let optionalRaw = [ Some "hi" ; None ]
|
||||||
|
|
||||||
|
[<TestCaseSource(nameof optionalRaw)>]
|
||||||
|
let ``Consume options, raw`` (s : string option) : unit = s |> shouldEqual s
|
||||||
|
|
||||||
[<OneTimeTearDown>]
|
[<OneTimeTearDown>]
|
||||||
let tearDown () =
|
let tearDown () =
|
||||||
|
@@ -291,9 +291,10 @@ module Filter =
|
|||||||
fun a b -> inner1 a b || inner2 a b
|
fun a b -> inner1 a b || inner2 a b
|
||||||
| Filter.Name (Match.Exact m) -> fun _fixture method -> method.Method.Name = m
|
| Filter.Name (Match.Exact m) -> fun _fixture method -> method.Method.Name = m
|
||||||
| Filter.Name (Match.Contains m) -> fun _fixture method -> method.Method.Name.Contains m
|
| Filter.Name (Match.Contains m) -> fun _fixture method -> method.Method.Name.Contains m
|
||||||
| Filter.FullyQualifiedName (Match.Exact m) -> fun fixture method -> (fixture.Name + method.Method.Name) = m
|
| Filter.FullyQualifiedName (Match.Exact m) ->
|
||||||
|
fun _fixture method -> (method.Method.DeclaringType.FullName + "." + method.Method.Name) = m
|
||||||
| Filter.FullyQualifiedName (Match.Contains m) ->
|
| Filter.FullyQualifiedName (Match.Contains m) ->
|
||||||
fun fixture method -> (fixture.Name + method.Method.Name).Contains m
|
fun _fixture method -> (method.Method.DeclaringType.FullName + "." + method.Method.Name).Contains m
|
||||||
| Filter.TestCategory (Match.Contains m) ->
|
| Filter.TestCategory (Match.Contains m) ->
|
||||||
fun _fixture method -> method.Categories |> List.exists (fun cat -> cat.Contains m)
|
fun _fixture method -> method.Categories |> List.exists (fun cat -> cat.Contains m)
|
||||||
| Filter.TestCategory (Match.Exact m) -> fun _fixture method -> method.Categories |> List.contains m
|
| Filter.TestCategory (Match.Exact m) -> fun _fixture method -> method.Categories |> List.contains m
|
||||||
|
@@ -332,6 +332,7 @@ module TestFixture =
|
|||||||
yield
|
yield
|
||||||
Guid.NewGuid (),
|
Guid.NewGuid (),
|
||||||
match arg with
|
match arg with
|
||||||
|
| null -> [| (null : obj) |]
|
||||||
| :? Tuple<obj, obj> as (a, b) -> [| a ; b |]
|
| :? Tuple<obj, obj> as (a, b) -> [| a ; b |]
|
||||||
| :? Tuple<obj, obj, obj> as (a, b, c) -> [| a ; b ; c |]
|
| :? Tuple<obj, obj, obj> as (a, b, c) -> [| a ; b ; c |]
|
||||||
| :? Tuple<obj, obj, obj, obj> as (a, b, c, d) -> [| a ; b ; c ; d |]
|
| :? Tuple<obj, obj, obj, obj> as (a, b, c, d) -> [| a ; b ; c ; d |]
|
||||||
|
Reference in New Issue
Block a user