From 4533f5e9b3d05a17dc7e7e45486da558904d009a Mon Sep 17 00:00:00 2001 From: Smaug123 <3138005+Smaug123@users.noreply.github.com> Date: Tue, 28 May 2024 20:08:10 +0100 Subject: [PATCH 1/5] Add CONTRIBUTING --- CONTRIBUTING.md | 49 +++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 41 insertions(+), 8 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index d026637..a290b66 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,4 +1,30 @@ -# On your first checkout +# Contributing + +The main project fork lives [on GitHub](https://github.com/G-Research/ShapeSifter). + +Please note that while we do accept contributions, this library is primarily built and maintained to serve the needs of G-Research, and our main priorities are to ensure that it continues to do so. +We provide the library in the hope that it will be useful, but we can't sink unlimited amounts of effort into its maintenance, so please forgive us if we choose not to accept some particular contribution you propose. +We will try to address issues and review incoming pull requests, but we do so on a [best-effort](https://en.wikipedia.org/wiki/Best-effort_delivery) basis. + +In practice, this means that we are more likely to accept correctness fixes, but we may be more conservative about accepting new features, and we can't promise to take every contribution; and if you have encountered an issue which we ourselves do not encounter, we may or may not choose to fix it. +(For such problems, we are much more likely to review and accept a pull request that proposes a fix, than to create a fix from scratch.) + +## Issues + +Please raise bug reports and feature requests as Issues on [the main GitHub project](https://github.com/G-Research/ShapeSifter/issues). + +## Pull requests + +Before embarking on a large change, we strongly recommend checking via a GitHub Issue first that we are likely to accept it. + +You may find that the following guidelines will help you produce a change that we accept: + +* Keep your change as small and focused as is practical. +* Ensure that your change is thoroughly tested. +* Document any choices you make which are not immediately obvious. +* Explain why your change is necessary or desirable. + +## On your first checkout There are pull request checks on this repo, enforcing [Fantomas](https://github.com/fsprojects/fantomas/)-compliant formatting. After checking out the repo, you may wish to add a pre-push hook to ensure locally that formatting is complete, rather than having to wait for the CI checks to tell you that you haven't formatted your code. @@ -11,11 +37,18 @@ Before your first push (but only once), you will need to install the [.NET local dotnet tool restore ``` -Some commits (such as big-bang formatting commits) are recorded for convenience in `.git-blame-ignore-revs`. -Consider performing the following command to have `git blame` ignore these commits: -```bash -git config blame.ignoreRevsFile .git-blame-ignore-revs -``` +## Dependencies + +For maximum compatibility, this project targets the earliest version of `FSharp.Core` that is practical (see the [Notes and Guidance on FSharp.Core](https://fsharp.github.io/fsharp-compiler-docs/fsharp-core-notes.html) for more details). +It targets `netstandard2.0` so that it can be used in the legacy .NET Framework. + +We try to keep `ShapeSifter`'s dependency footprint small. + +## Branch strategy + +Releases are made from the `main` branch. + +## License + +This project is licensed with the MIT license, a copy of which you can find at the repository root. -# License -This project is licensed under the MIT licence, a copy of which you can find at the repository root. From cd9f578ee9f406c84304cc9ee1c830fde05cd17c Mon Sep 17 00:00:00 2001 From: Smaug123 <3138005+Smaug123@users.noreply.github.com> Date: Tue, 28 May 2024 20:11:12 +0100 Subject: [PATCH 2/5] Rename --- ShapeSifter.Test/Attribute.fs | 4 ++-- ShapeSifter.Test/TestPatterns.fs | 6 +++--- ShapeSifter.Test/TestRecord.fs | 6 +++--- ShapeSifter.Test/TestSurface.fs | 6 +++--- ShapeSifter.Test/TestType.fs | 4 ++-- ShapeSifter.Test/TestUnion.fs | 6 +++--- ShapeSifter/Conv.fs | 2 +- ShapeSifter/ConvCrates.fs | 2 +- ShapeSifter/Fields.fs | 2 +- ShapeSifter/Patterns.fs | 2 +- ShapeSifter/Reflection.fs | 2 +- ShapeSifter/TeqCrates.fs | 4 ++-- ShapeSifter/Tuple.fs | 4 ++-- ShapeSifter/Type.fs | 4 ++-- ShapeSifter/TypeListCrate.fs | 2 +- ShapeSifter/TypeParameterCrate.fs | 2 +- ShapeSifter/TypePatterns.fs | 2 +- ShapeSifter/Unreachable.fs | 2 +- 18 files changed, 31 insertions(+), 31 deletions(-) diff --git a/ShapeSifter.Test/Attribute.fs b/ShapeSifter.Test/Attribute.fs index 756a4bb..c777d23 100644 --- a/ShapeSifter.Test/Attribute.fs +++ b/ShapeSifter.Test/Attribute.fs @@ -1,6 +1,6 @@ -namespace TeqCrate.Test +namespace ShapeSifter.Test -open TeqCrate +open ShapeSifter [] module Attribute = diff --git a/ShapeSifter.Test/TestPatterns.fs b/ShapeSifter.Test/TestPatterns.fs index c326e4a..95b1bbb 100644 --- a/ShapeSifter.Test/TestPatterns.fs +++ b/ShapeSifter.Test/TestPatterns.fs @@ -1,8 +1,8 @@ -namespace TeqCrate.Test +namespace ShapeSifter.Test open HCollections -open TeqCrate -open TeqCrate.Patterns +open ShapeSifter +open ShapeSifter.Patterns open TypeEquality open Xunit diff --git a/ShapeSifter.Test/TestRecord.fs b/ShapeSifter.Test/TestRecord.fs index 224118c..250dce0 100644 --- a/ShapeSifter.Test/TestRecord.fs +++ b/ShapeSifter.Test/TestRecord.fs @@ -1,12 +1,12 @@ -namespace TeqCrate.Test +namespace ShapeSifter.Test open System open Xunit open FsUnitTyped -open TeqCrate -open TeqCrate.Patterns +open ShapeSifter +open ShapeSifter.Patterns module TestRecord = diff --git a/ShapeSifter.Test/TestSurface.fs b/ShapeSifter.Test/TestSurface.fs index 3a14b69..ba2ef88 100644 --- a/ShapeSifter.Test/TestSurface.fs +++ b/ShapeSifter.Test/TestSurface.fs @@ -1,7 +1,7 @@ -namespace TeqCrate.Test +namespace ShapeSifter.Test open ApiSurface -open TeqCrate +open ShapeSifter open Xunit module TestSurface = @@ -20,4 +20,4 @@ module TestSurface = [] let ``Ensure version is monotonic`` () = - MonotonicVersion.validate assembly "TeqCrate" + MonotonicVersion.validate assembly "ShapeSifter" diff --git a/ShapeSifter.Test/TestType.fs b/ShapeSifter.Test/TestType.fs index 4a4cda8..e631e6a 100644 --- a/ShapeSifter.Test/TestType.fs +++ b/ShapeSifter.Test/TestType.fs @@ -1,7 +1,7 @@ -namespace TeqCrate.Test +namespace ShapeSifter.Test open System -open TeqCrate +open ShapeSifter open Xunit [] diff --git a/ShapeSifter.Test/TestUnion.fs b/ShapeSifter.Test/TestUnion.fs index 0d425c1..d62ecf5 100644 --- a/ShapeSifter.Test/TestUnion.fs +++ b/ShapeSifter.Test/TestUnion.fs @@ -1,12 +1,12 @@ -namespace TeqCrate.Test +namespace ShapeSifter.Test open System open Xunit open FsUnitTyped -open TeqCrate -open TeqCrate.Patterns +open ShapeSifter +open ShapeSifter.Patterns module TestUnion = diff --git a/ShapeSifter/Conv.fs b/ShapeSifter/Conv.fs index 7081ad7..66a7a43 100644 --- a/ShapeSifter/Conv.fs +++ b/ShapeSifter/Conv.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter [] [] diff --git a/ShapeSifter/ConvCrates.fs b/ShapeSifter/ConvCrates.fs index 7f8a1ae..b971b33 100644 --- a/ShapeSifter/ConvCrates.fs +++ b/ShapeSifter/ConvCrates.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System.Reflection open HCollections diff --git a/ShapeSifter/Fields.fs b/ShapeSifter/Fields.fs index b7749e6..e8b6cf0 100644 --- a/ShapeSifter/Fields.fs +++ b/ShapeSifter/Fields.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open Microsoft.FSharp.Reflection open System.Reflection diff --git a/ShapeSifter/Patterns.fs b/ShapeSifter/Patterns.fs index 096e8c1..400ca3b 100644 --- a/ShapeSifter/Patterns.fs +++ b/ShapeSifter/Patterns.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System open TypeEquality diff --git a/ShapeSifter/Reflection.fs b/ShapeSifter/Reflection.fs index d6cf872..e56c85e 100644 --- a/ShapeSifter/Reflection.fs +++ b/ShapeSifter/Reflection.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open Microsoft.FSharp.Quotations open Microsoft.FSharp.Quotations.Patterns diff --git a/ShapeSifter/TeqCrates.fs b/ShapeSifter/TeqCrates.fs index 26a33c3..efe85ff 100644 --- a/ShapeSifter/TeqCrates.fs +++ b/ShapeSifter/TeqCrates.fs @@ -1,7 +1,7 @@ -namespace TeqCrate +namespace ShapeSifter open System.Collections.Generic -open TeqCrate.TypePatterns +open ShapeSifter.TypePatterns open TypeEquality diff --git a/ShapeSifter/Tuple.fs b/ShapeSifter/Tuple.fs index 99ad529..f052dee 100644 --- a/ShapeSifter/Tuple.fs +++ b/ShapeSifter/Tuple.fs @@ -1,7 +1,7 @@ -namespace TeqCrate +namespace ShapeSifter open HCollections -open TeqCrate.Patterns +open ShapeSifter.Patterns [] module Tuple = diff --git a/ShapeSifter/Type.fs b/ShapeSifter/Type.fs index ff74b02..76af6af 100644 --- a/ShapeSifter/Type.fs +++ b/ShapeSifter/Type.fs @@ -1,7 +1,7 @@ -namespace TeqCrate +namespace ShapeSifter open System -open TeqCrate.TypePatterns +open ShapeSifter.TypePatterns [] module Type = diff --git a/ShapeSifter/TypeListCrate.fs b/ShapeSifter/TypeListCrate.fs index 2194934..74ce3a5 100644 --- a/ShapeSifter/TypeListCrate.fs +++ b/ShapeSifter/TypeListCrate.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open HCollections open System diff --git a/ShapeSifter/TypeParameterCrate.fs b/ShapeSifter/TypeParameterCrate.fs index 1af0806..7525381 100644 --- a/ShapeSifter/TypeParameterCrate.fs +++ b/ShapeSifter/TypeParameterCrate.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System diff --git a/ShapeSifter/TypePatterns.fs b/ShapeSifter/TypePatterns.fs index f749e6a..be9517b 100644 --- a/ShapeSifter/TypePatterns.fs +++ b/ShapeSifter/TypePatterns.fs @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System.Reflection open Microsoft.FSharp.Reflection diff --git a/ShapeSifter/Unreachable.fs b/ShapeSifter/Unreachable.fs index 1bcadc6..68f27c1 100644 --- a/ShapeSifter/Unreachable.fs +++ b/ShapeSifter/Unreachable.fs @@ -1,3 +1,3 @@ -namespace TeqCrate +namespace ShapeSifter exception internal Unreachable From 1e2b4616e7bcf8947f0c932044a231819a12d16f Mon Sep 17 00:00:00 2001 From: Smaug123 <3138005+Smaug123@users.noreply.github.com> Date: Tue, 28 May 2024 20:28:01 +0100 Subject: [PATCH 3/5] Migrate to NUnit --- ShapeSifter.Test/ShapeSifter.Test.fsproj | 13 +- ShapeSifter.Test/TestPatterns.fs | 118 ++++---- ShapeSifter.Test/TestRecord.fs | 7 +- ShapeSifter.Test/TestSurface.fs | 14 +- ShapeSifter.Test/TestType.fs | 11 +- ShapeSifter.Test/TestUnion.fs | 7 +- ShapeSifter/Conv.fsi | 2 +- ShapeSifter/ConvCrates.fsi | 2 +- ShapeSifter/Fields.fsi | 2 +- ShapeSifter/Patterns.fsi | 2 +- ShapeSifter/Reflection.fsi | 2 +- ShapeSifter/SurfaceBaseline.txt | 362 +++++++++++------------ ShapeSifter/TeqCrates.fsi | 2 +- ShapeSifter/Tuple.fsi | 2 +- ShapeSifter/Type.fsi | 2 +- ShapeSifter/TypeListCrate.fsi | 2 +- ShapeSifter/TypeParameterCrate.fsi | 2 +- ShapeSifter/TypePatterns.fsi | 2 +- ShapeSifter/version.json | 7 +- 19 files changed, 282 insertions(+), 279 deletions(-) diff --git a/ShapeSifter.Test/ShapeSifter.Test.fsproj b/ShapeSifter.Test/ShapeSifter.Test.fsproj index c66e7f4..1481222 100644 --- a/ShapeSifter.Test/ShapeSifter.Test.fsproj +++ b/ShapeSifter.Test/ShapeSifter.Test.fsproj @@ -18,15 +18,10 @@ - - - - - - all - runtime; build; native; contentfiles; analyzers - - + + + + diff --git a/ShapeSifter.Test/TestPatterns.fs b/ShapeSifter.Test/TestPatterns.fs index 95b1bbb..757ec6d 100644 --- a/ShapeSifter.Test/TestPatterns.fs +++ b/ShapeSifter.Test/TestPatterns.fs @@ -1,23 +1,24 @@ namespace ShapeSifter.Test open HCollections +open NUnit.Framework +open FsUnitTyped open ShapeSifter open ShapeSifter.Patterns open TypeEquality -open Xunit -[] +[] module TestPatterns = - [] + [] let ``Teq active pattern distinguishes int from string`` () = let t1 = tType let t2 = tType match t1 with - | Teq t2 teq -> Assert.True false - | _ -> Assert.True true + | Teq t2 teq -> failwith "Expected int != string" + | _ -> () let tryGetArrayLength (arr : 'a) : int option = match tType<'a> with @@ -28,11 +29,11 @@ module TestPatterns = } | _ -> None - [] + [] let ``Array active pattern recognises an array`` () = - let arr = [| "foo" ; "bar" |] - Assert.Equal (Some 2, tryGetArrayLength arr) + tryGetArrayLength arr + |> shouldEqual (Some 2) let tryGetListLength (xs : 'a) : int option = match tType<'a> with @@ -44,11 +45,11 @@ module TestPatterns = } | _ -> None - [] + [] let ``List active pattern recognises a list`` () = - let xs = [ 1..10 ] - Assert.Equal (Some 10, tryGetListLength xs) + tryGetListLength xs + |> shouldEqual (Some 10) let tryGetMapCount (map : 'a) : int option = match tType<'a> with @@ -60,20 +61,21 @@ module TestPatterns = } | _ -> None - [] + [] let ``Map active pattern recognises a map`` () = - let map = Map.empty |> Map.add "foo" 3 |> Map.add "bar" 12 - Assert.Equal (Some 2, tryGetMapCount map) + tryGetMapCount map + |> shouldEqual (Some 2) - [] + [] let ``Tuple active pattern recognises a tuple`` () = let tuple = 5, "hello", false, 8, 2 let sumOfInts = Tuple.tryFoldTuple (HListFolder.makeElementFolder (+)) 0 tuple - Assert.Equal (Some 15, sumOfInts) + sumOfInts + |> shouldEqual (Some 15) - [] + [] let ``Fun active pattern recognises a function`` () = match tType string> with @@ -84,12 +86,12 @@ module TestPatterns = member __.Eval (teq : Teq string, 'a -> 'b>) = typeof<'a>, typeof<'b> } - Assert.Equal (typeof, dom) - Assert.Equal (typeof, ran) + dom |> shouldEqual typeof + ran |> shouldEqual typeof - | _ -> Assert.True false + | _ -> failwith "expected a function type" - [] + [] let ``Pair active pattern recognises a pair`` () = match tType with @@ -100,22 +102,22 @@ module TestPatterns = member __.Eval (teq : Teq) = typeof<'a>, typeof<'b> } - Assert.Equal (typeof, t1) - Assert.Equal (typeof, t2) + t1 |> shouldEqual typeof + t2 |> shouldEqual typeof - | _ -> Assert.True false + | _ -> failwith "expected a pair type" - [] + [] let ``Unit active pattern recognises a unit`` () = // This test is useful because there are certain aspects of F# which behave oddly // in the presence of unit. (It turns out that units are just fine here.) match tType with - | Unit teq -> Assert.True (Teq.castFrom teq () = ()) + | Unit teq -> Teq.castFrom teq () |> shouldEqual () - | _ -> Assert.True false + | _ -> failwith "expected a unit type" - [] + [] let ``Triple active pattern recognises a triple`` () = match tType with @@ -127,11 +129,11 @@ module TestPatterns = typeof<'a>, typeof<'b>, typeof<'c> } - Assert.Equal (typeof, t1) - Assert.Equal (typeof, t2) - Assert.Equal (typeof, t3) + t1 |> shouldEqual typeof + t2 |> shouldEqual typeof + t3 |> shouldEqual typeof - | _ -> Assert.True false + | _ -> failwith "expected a triple" type TestRecord = { @@ -165,7 +167,7 @@ module TestPatterns = |> Some | _ -> None - [] + [] let ``Record active pattern recognises a record`` () = let r = @@ -180,7 +182,7 @@ module TestPatterns = let expected = Some [ "Baz", "world" ; "Foo", "hello" ] - Assert.Equal (expected, pairs) + pairs |> shouldEqual expected type TestUnion = | Foo @@ -188,7 +190,7 @@ module TestPatterns = | Baz of string * float | Quux of string - [] + [] let ``Union active pattern recognises a union`` () = let testValue = Bar (1234, "test", true) @@ -202,7 +204,7 @@ module TestPatterns = let expectedNames = [ "Foo" ; "Bar" ; "Baz" ; "Quux" ] let actualNames = names |> List.map TypeField.name - Assert.Equal (expectedNames, actualNames) + actualNames |> shouldEqual expectedNames let expectedUnionType = tType<(unit -> (int * string * bool) -> (string * float) -> string -> unit) HUnion> @@ -212,20 +214,20 @@ module TestPatterns = let converted = testValue |> conv.To |> Teq.castTo teq match HUnion.split converted with - | Choice1Of2 v -> false + | Choice1Of2 v -> failwith "expected Choice2Of2" | Choice2Of2 union -> match HUnion.split union with | Choice1Of2 (i : int, s : string, b : bool) -> let convertedBack = converted |> Teq.castFrom teq |> conv.From true - | Choice2Of2 _ -> false - | _ -> false + | Choice2Of2 _ -> failwith "expected Choice1Of2" + | _ -> failwith "expected Teq" } - | _ -> false + | _ -> failwith "expected Union" - Assert.True result + result |> shouldEqual true - [] + [] let ``SumOfProducts active pattern recognises a union`` () = let testValue = Bar (1234, "test", true) @@ -238,7 +240,7 @@ module TestPatterns = member __.Eval names ts (conv : Conv) = let expectedNames = [ "Foo" ; "Bar" ; "Baz" ; "Quux" ] - Assert.Equal (expectedNames, names) + names |> shouldEqual expectedNames let expectedUnionType = tType< @@ -254,18 +256,18 @@ module TestPatterns = let converted = testValue |> conv.To |> Teq.castTo teq match SumOfProducts.split converted with - | Choice1Of2 v -> false + | Choice1Of2 v -> failwith "expected Choice2Of2" | Choice2Of2 sop -> match SumOfProducts.split sop with | Choice1Of2 (xs : (int -> string -> bool -> unit) HList) -> let convertedBack = converted |> Teq.castFrom teq |> conv.From true - | Choice2Of2 _ -> false - | _ -> false + | Choice2Of2 _ -> failwith "expected Choice1Of2" + | _ -> failwith "expected a Teq" } - | _ -> false + | _ -> failwith "expected a SumOfProducts" - Assert.True result + result |> shouldEqual true type private TestPrivateRecord = { @@ -274,7 +276,7 @@ module TestPatterns = PrivateBaz : string } - [] + [] let ``Record active pattern recognises a private record`` () = let r = @@ -289,7 +291,7 @@ module TestPatterns = let expected = Some [ "PrivateBaz", "world" ; "PrivateFoo", "hello" ] - Assert.Equal (expected, pairs) + pairs |> shouldEqual expected let result = match tType with @@ -302,13 +304,13 @@ module TestPatterns = let actualNames = names |> List.map TypeField.name - Assert.Equal (expectedNames, actualNames) + actualNames |> shouldEqual expectedNames TypeList.toTypes ts = [ typeof ; typeof ; typeof ] } - | _ -> false + | _ -> failwith "expected a record" - Assert.True result + result |> shouldEqual true type TestInternallyPrivateRecord = private @@ -318,7 +320,7 @@ module TestPatterns = InternallyPrivateBaz : string } - [] + [] let ``Record active pattern recognises a public record whose fields are private`` () = let r = @@ -334,7 +336,7 @@ module TestPatterns = let expected = Some [ "InternallyPrivateBaz", "world" ; "InternallyPrivateFoo", "hello" ] - Assert.Equal (expected, pairs) + pairs |> shouldEqual expected let result = match tType with @@ -348,10 +350,10 @@ module TestPatterns = let actualNames = names |> List.map TypeField.name - Assert.Equal (expectedNames, actualNames) + actualNames |> shouldEqual expectedNames TypeList.toTypes ts = [ typeof ; typeof ; typeof ] } - | _ -> false + | _ -> failwith "expected a record" - Assert.True result + result |> shouldEqual true diff --git a/ShapeSifter.Test/TestRecord.fs b/ShapeSifter.Test/TestRecord.fs index 250dce0..8eed3ed 100644 --- a/ShapeSifter.Test/TestRecord.fs +++ b/ShapeSifter.Test/TestRecord.fs @@ -2,12 +2,13 @@ namespace ShapeSifter.Test open System -open Xunit open FsUnitTyped +open NUnit.Framework open ShapeSifter open ShapeSifter.Patterns +[] module TestRecord = [] @@ -29,7 +30,7 @@ module TestRecord = Field4 : int64 } - [] + [] let ``Custom attributes are populated correctly for record fields`` () = let data = match tType with @@ -77,7 +78,7 @@ module TestRecord = Field2 : string } - [] + [] let ``Can obtain field data for private-implementation records`` () = let data = match tType with diff --git a/ShapeSifter.Test/TestSurface.fs b/ShapeSifter.Test/TestSurface.fs index ba2ef88..c2b330c 100644 --- a/ShapeSifter.Test/TestSurface.fs +++ b/ShapeSifter.Test/TestSurface.fs @@ -1,23 +1,27 @@ namespace ShapeSifter.Test open ApiSurface +open NUnit.Framework open ShapeSifter -open Xunit +[] module TestSurface = let assembly = typeof.Assembly - [] + [] let ``Ensure API surface has not been modified`` () = ApiSurface.assertIdentical assembly - [] + [] + [] let ``Update API surface`` () = ApiSurface.writeAssemblyBaseline assembly - [] + [] let ``Ensure public API is fully documented`` () = DocCoverage.assertFullyDocumented assembly - [] + (* + [] let ``Ensure version is monotonic`` () = MonotonicVersion.validate assembly "ShapeSifter" + *) diff --git a/ShapeSifter.Test/TestType.fs b/ShapeSifter.Test/TestType.fs index e631e6a..6db2921 100644 --- a/ShapeSifter.Test/TestType.fs +++ b/ShapeSifter.Test/TestType.fs @@ -1,10 +1,11 @@ namespace ShapeSifter.Test open System +open NUnit.Framework +open FsUnitTyped open ShapeSifter -open Xunit -[] +[] module TestType = let testCases = @@ -24,6 +25,6 @@ module TestType = ] |> List.map (fun (t, expected) -> [| box t ; box expected |]) - [] - [] - let ``Test print`` (t : Type, expected : string) : unit = Assert.Equal (expected, Type.print t) + [] + [] + let ``Test print`` (t : Type, expected : string) : unit = Type.print t |> shouldEqual expected diff --git a/ShapeSifter.Test/TestUnion.fs b/ShapeSifter.Test/TestUnion.fs index d62ecf5..9a9ba99 100644 --- a/ShapeSifter.Test/TestUnion.fs +++ b/ShapeSifter.Test/TestUnion.fs @@ -2,12 +2,13 @@ namespace ShapeSifter.Test open System -open Xunit +open NUnit.Framework open FsUnitTyped open ShapeSifter open ShapeSifter.Patterns +[] module TestUnion = [] @@ -24,7 +25,7 @@ module TestUnion = | [] Case3 | [] Case4 of int64 - [] + [] let ``Custom attributes are populated correctly for union cases`` () = let data = match tType with @@ -66,7 +67,7 @@ module TestUnion = | Field1 | [] Field2 - [] + [] let ``Can obtain field data for private-implementation unions`` () = let data = match tType with diff --git a/ShapeSifter/Conv.fsi b/ShapeSifter/Conv.fsi index 936b161..ff7dd36 100644 --- a/ShapeSifter/Conv.fsi +++ b/ShapeSifter/Conv.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter /// The Conv type (short for converter) is essentially a bi-directional map between two types. /// For any pair of types 'a and 'b, a Conv<'a, 'b> is a pair of functions diff --git a/ShapeSifter/ConvCrates.fsi b/ShapeSifter/ConvCrates.fsi index 0b923d1..9e9530b 100644 --- a/ShapeSifter/ConvCrates.fsi +++ b/ShapeSifter/ConvCrates.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open HCollections diff --git a/ShapeSifter/Fields.fsi b/ShapeSifter/Fields.fsi index 81915a7..1fbd84f 100644 --- a/ShapeSifter/Fields.fsi +++ b/ShapeSifter/Fields.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open Microsoft.FSharp.Reflection open System.Reflection diff --git a/ShapeSifter/Patterns.fsi b/ShapeSifter/Patterns.fsi index b5ab967..db8849d 100644 --- a/ShapeSifter/Patterns.fsi +++ b/ShapeSifter/Patterns.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System open TypeEquality diff --git a/ShapeSifter/Reflection.fsi b/ShapeSifter/Reflection.fsi index 6e8b31e..a4f701d 100644 --- a/ShapeSifter/Reflection.fsi +++ b/ShapeSifter/Reflection.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open Microsoft.FSharp.Quotations open System diff --git a/ShapeSifter/SurfaceBaseline.txt b/ShapeSifter/SurfaceBaseline.txt index 2255a95..33fb193 100644 --- a/ShapeSifter/SurfaceBaseline.txt +++ b/ShapeSifter/SurfaceBaseline.txt @@ -1,181 +1,181 @@ -TeqCrate.ArrayTeqCrate inherit obj -TeqCrate.ArrayTeqCrate.make [static method]: unit -> 'a [] TeqCrate.ArrayTeqCrate -TeqCrate.ArrayTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.ArrayTeqCrate option -TeqCrate.ArrayTeqCrate`1 - interface with 1 member(s) -TeqCrate.ArrayTeqCrate`1.Apply [method]: TeqCrate.ArrayTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.ArrayTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.ArrayTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b []> -> 'ret -TeqCrate.Conv inherit obj -TeqCrate.Conv.compose [static method]: TeqCrate.Conv<'a, 'b> -> TeqCrate.Conv<'b, 'c> -> TeqCrate.Conv<'a, 'c> -TeqCrate.Conv.make [static method]: ('a -> 'b) -> ('b -> 'a) -> TeqCrate.Conv<'a, 'b> -TeqCrate.Conv`2 inherit obj -TeqCrate.Conv`2..ctor [constructor]: ('a -> 'b, 'b -> 'a) -TeqCrate.Conv`2.From [property]: [read-only] 'b -> 'a -TeqCrate.Conv`2.get_From [method]: unit -> ('b -> 'a) -TeqCrate.Conv`2.get_To [method]: unit -> ('a -> 'b) -TeqCrate.Conv`2.To [property]: [read-only] 'a -> 'b -TeqCrate.DictionaryTeqCrate inherit obj -TeqCrate.DictionaryTeqCrate.make [static method]: unit -> System.Collections.Generic.Dictionary<'k, 'v> TeqCrate.DictionaryTeqCrate -TeqCrate.DictionaryTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.DictionaryTeqCrate option -TeqCrate.DictionaryTeqCrate`1 - interface with 1 member(s) -TeqCrate.DictionaryTeqCrate`1.Apply [method]: TeqCrate.DictionaryTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.DictionaryTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.DictionaryTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, System.Collections.Generic.Dictionary<'k, 'v>> -> 'ret -TeqCrate.FunTeqCrate inherit obj -TeqCrate.FunTeqCrate.make [static method]: unit -> ('a -> 'b) TeqCrate.FunTeqCrate -TeqCrate.FunTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.FunTeqCrate option -TeqCrate.FunTeqCrate`1 - interface with 1 member(s) -TeqCrate.FunTeqCrate`1.Apply [method]: TeqCrate.FunTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.FunTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.FunTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b -> 'c> -> 'ret -TeqCrate.ListTeqCrate inherit obj -TeqCrate.ListTeqCrate.make [static method]: unit -> 'a list TeqCrate.ListTeqCrate -TeqCrate.ListTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.ListTeqCrate option -TeqCrate.ListTeqCrate`1 - interface with 1 member(s) -TeqCrate.ListTeqCrate`1.Apply [method]: TeqCrate.ListTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.ListTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.ListTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b list> -> 'ret -TeqCrate.MapTeqCrate inherit obj -TeqCrate.MapTeqCrate.make [static method]: unit -> Map<'k, 'v> TeqCrate.MapTeqCrate -TeqCrate.MapTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.MapTeqCrate option -TeqCrate.MapTeqCrate`1 - interface with 1 member(s) -TeqCrate.MapTeqCrate`1.Apply [method]: TeqCrate.MapTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.MapTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.MapTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, Map<'k, 'v>> -> 'ret -TeqCrate.OptionTeqCrate inherit obj -TeqCrate.OptionTeqCrate.make [static method]: unit -> 'a option TeqCrate.OptionTeqCrate -TeqCrate.OptionTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.OptionTeqCrate option -TeqCrate.OptionTeqCrate`1 - interface with 1 member(s) -TeqCrate.OptionTeqCrate`1.Apply [method]: TeqCrate.OptionTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.OptionTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.OptionTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b option> -> 'ret -TeqCrate.PairTeqCrate inherit obj -TeqCrate.PairTeqCrate.make [static method]: unit -> ('a * 'b) TeqCrate.PairTeqCrate -TeqCrate.PairTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.PairTeqCrate option -TeqCrate.PairTeqCrate`1 - interface with 1 member(s) -TeqCrate.PairTeqCrate`1.Apply [method]: TeqCrate.PairTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.PairTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.PairTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, ('b * 'c)> -> 'ret -TeqCrate.Patterns inherit obj -TeqCrate.Patterns+TType`1 inherit obj, implements 'a TeqCrate.Patterns+TType System.IEquatable, System.Collections.IStructuralEquatable, 'a TeqCrate.Patterns+TType System.IComparable, System.IComparable, System.Collections.IStructuralComparable - union type with 1 cases -TeqCrate.Patterns+TType`1.get_Item [method]: unit -> unit -TeqCrate.Patterns+TType`1.get_Tag [method]: unit -> int -TeqCrate.Patterns+TType`1.Item [property]: [read-only] unit -TeqCrate.Patterns+TType`1.NewTType [static method]: unit -> 'a TeqCrate.Patterns+TType -TeqCrate.Patterns+TType`1.Tag [property]: [read-only] int -TeqCrate.Patterns.tType [static method]: unit -> 'a TeqCrate.Patterns+TType -TeqCrate.Patterns.|Array|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.ArrayTeqCrate option -TeqCrate.Patterns.|Bool|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, bool> option -TeqCrate.Patterns.|DateTime|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, System.DateTime> option -TeqCrate.Patterns.|Dictionary|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.DictionaryTeqCrate option -TeqCrate.Patterns.|Float|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, float> option -TeqCrate.Patterns.|Fun|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.FunTeqCrate option -TeqCrate.Patterns.|Int64|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, System.Int64> option -TeqCrate.Patterns.|Int|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, int> option -TeqCrate.Patterns.|List|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.ListTeqCrate option -TeqCrate.Patterns.|Map|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.MapTeqCrate option -TeqCrate.Patterns.|Option|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.OptionTeqCrate option -TeqCrate.Patterns.|Pair|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.PairTeqCrate option -TeqCrate.Patterns.|Record|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.RecordConvCrate option -TeqCrate.Patterns.|ResizeArray|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.ResizeArrayTeqCrate option -TeqCrate.Patterns.|Seq|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.SeqTeqCrate option -TeqCrate.Patterns.|Set|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.SetTeqCrate option -TeqCrate.Patterns.|String|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, string> option -TeqCrate.Patterns.|SumOfProducts|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.SumOfProductsConvCrate option -TeqCrate.Patterns.|Teq|_| [static method]: 'b TeqCrate.Patterns+TType -> 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, 'b> option -TeqCrate.Patterns.|TimeSpan|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, System.TimeSpan> option -TeqCrate.Patterns.|Triple|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.TripleTeqCrate option -TeqCrate.Patterns.|Tuple|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.TupleConvCrate option -TeqCrate.Patterns.|Union|_| [static method]: 'a TeqCrate.Patterns+TType -> 'a TeqCrate.UnionConvCrate option -TeqCrate.Patterns.|Unit|_| [static method]: 'a TeqCrate.Patterns+TType -> TypeEquality.Teq<'a, unit> option -TeqCrate.RecordConvCrate inherit obj -TeqCrate.RecordConvCrate.tryMake [static method]: unit -> 'record TeqCrate.RecordConvCrate option -TeqCrate.RecordConvCrate`1 - interface with 1 member(s) -TeqCrate.RecordConvCrate`1.Apply [method]: TeqCrate.RecordConvEvaluator<'record, 'ret> -> 'ret -TeqCrate.RecordConvEvaluator`2 - interface with 1 member(s) -TeqCrate.RecordConvEvaluator`2.Eval [method]: System.Reflection.PropertyInfo TeqCrate.TypeField list -> 'ts HCollections.TypeList -> TeqCrate.Conv<'record, 'ts HCollections.HList> -> 'ret -TeqCrate.Reflection inherit obj -TeqCrate.Reflection.invokeStaticMethod [static method]: Microsoft.FSharp.Quotations.FSharpExpr -> (System.Type seq -> obj seq -> obj) -TeqCrate.ResizeArrayTeqCrate inherit obj -TeqCrate.ResizeArrayTeqCrate.make [static method]: unit -> 'a System.Collections.Generic.List TeqCrate.ResizeArrayTeqCrate -TeqCrate.ResizeArrayTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.ResizeArrayTeqCrate option -TeqCrate.ResizeArrayTeqCrate`1 - interface with 1 member(s) -TeqCrate.ResizeArrayTeqCrate`1.Apply [method]: TeqCrate.ResizeArrayTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.ResizeArrayTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.ResizeArrayTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b System.Collections.Generic.List> -> 'ret -TeqCrate.SeqTeqCrate inherit obj -TeqCrate.SeqTeqCrate.make [static method]: unit -> 'a seq TeqCrate.SeqTeqCrate -TeqCrate.SeqTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.SeqTeqCrate option -TeqCrate.SeqTeqCrate`1 - interface with 1 member(s) -TeqCrate.SeqTeqCrate`1.Apply [method]: TeqCrate.SeqTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.SeqTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.SeqTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b seq> -> 'ret -TeqCrate.SetTeqCrate inherit obj -TeqCrate.SetTeqCrate.make [static method]: unit -> 'a Microsoft.FSharp.Collections.FSharpSet TeqCrate.SetTeqCrate -TeqCrate.SetTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.SetTeqCrate option -TeqCrate.SetTeqCrate`1 - interface with 1 member(s) -TeqCrate.SetTeqCrate`1.Apply [method]: TeqCrate.SetTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.SetTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.SetTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b Microsoft.FSharp.Collections.FSharpSet> -> 'ret -TeqCrate.SumOfProductsConvCrate inherit obj -TeqCrate.SumOfProductsConvCrate.tryMake [static method]: unit -> 'union TeqCrate.SumOfProductsConvCrate option -TeqCrate.SumOfProductsConvCrate`1 - interface with 1 member(s) -TeqCrate.SumOfProductsConvCrate`1.Apply [method]: TeqCrate.SumOfProductsConvEvaluator<'union, 'ret> -> 'ret -TeqCrate.SumOfProductsConvEvaluator`2 - interface with 1 member(s) -TeqCrate.SumOfProductsConvEvaluator`2.Eval [method]: string list -> 'tss HCollections.TypeListList -> TeqCrate.Conv<'union, 'tss HCollections.SumOfProducts> -> 'ret -TeqCrate.TripleTeqCrate inherit obj -TeqCrate.TripleTeqCrate.make [static method]: unit -> ('a * 'b * 'c) TeqCrate.TripleTeqCrate -TeqCrate.TripleTeqCrate.tryMake [static method]: unit -> 'a TeqCrate.TripleTeqCrate option -TeqCrate.TripleTeqCrate`1 - interface with 1 member(s) -TeqCrate.TripleTeqCrate`1.Apply [method]: TeqCrate.TripleTeqEvaluator<'a, 'ret> -> 'ret -TeqCrate.TripleTeqEvaluator`2 - interface with 1 member(s) -TeqCrate.TripleTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, ('b * 'c * 'd)> -> 'ret -TeqCrate.Tuple inherit obj -TeqCrate.Tuple.tryFoldTuple [static method]: 'state HCollections.HListFolder -> 'state -> 'tuple -> 'state option -TeqCrate.TupleConvCrate inherit obj -TeqCrate.TupleConvCrate.tryMake [static method]: unit -> 'tuple TeqCrate.TupleConvCrate option -TeqCrate.TupleConvCrate`1 - interface with 1 member(s) -TeqCrate.TupleConvCrate`1.Apply [method]: TeqCrate.TupleConvEvaluator<'tuple, 'ret> -> 'ret -TeqCrate.TupleConvEvaluator`2 - interface with 1 member(s) -TeqCrate.TupleConvEvaluator`2.Eval [method]: 'ts HCollections.TypeList -> TeqCrate.Conv<'tuple, 'ts HCollections.HList> -> 'ret -TeqCrate.Type inherit obj -TeqCrate.Type.print [static method]: System.Type -> string -TeqCrate.TypeField inherit obj -TeqCrate.TypeField.attributes [static method]: 'case TeqCrate.TypeField -> System.Reflection.CustomAttributeData list -TeqCrate.TypeField.name [static method]: 'case TeqCrate.TypeField -> string -TeqCrate.TypeField`1 inherit obj -TeqCrate.TypeField`1..ctor [constructor]: (string, System.Reflection.CustomAttributeData list, 'case) -TeqCrate.TypeField`1.Attributes [property]: [read-only] System.Reflection.CustomAttributeData list -TeqCrate.TypeField`1.get_Attributes [method]: unit -> System.Reflection.CustomAttributeData list -TeqCrate.TypeField`1.get_Name [method]: unit -> string -TeqCrate.TypeField`1.get_RawCase [method]: unit -> 'case -TeqCrate.TypeField`1.Name [property]: [read-only] string -TeqCrate.TypeField`1.RawCase [property]: [read-only] 'case -TeqCrate.TypeListCrate - interface with 1 member(s) -TeqCrate.TypeListCrate.Apply [method]: 'ret TeqCrate.TypeListEvaluator -> 'ret -TeqCrate.TypeListCrateModule inherit obj -TeqCrate.TypeListCrateModule.make [static method]: 'ts HCollections.TypeList -> TeqCrate.TypeListCrate -TeqCrate.TypeListCrateModule.makeUntyped [static method]: System.Type list -> TeqCrate.TypeListCrate -TeqCrate.TypeListEvaluator`1 - interface with 1 member(s) -TeqCrate.TypeListEvaluator`1.Eval [method]: 'ts HCollections.TypeList -> 'ret -TeqCrate.TypeParameterCrate - interface with 1 member(s) -TeqCrate.TypeParameterCrate.Apply [method]: 'ret TeqCrate.TypeParameterEvaluator -> 'ret -TeqCrate.TypeParameterCrateModule inherit obj -TeqCrate.TypeParameterCrateModule.make [static method]: unit -> TeqCrate.TypeParameterCrate -TeqCrate.TypeParameterCrateModule.makeUntyped [static method]: System.Type -> TeqCrate.TypeParameterCrate -TeqCrate.TypeParameterCrateModule.toType [static method]: TeqCrate.TypeParameterCrate -> System.Type -TeqCrate.TypeParameterEvaluator`1 - interface with 1 member(s) -TeqCrate.TypeParameterEvaluator`1.Eval [method]: unit -> 'ret -TeqCrate.TypePatterns inherit obj -TeqCrate.TypePatterns.|Array|_| [static method]: System.Type -> System.Type option -TeqCrate.TypePatterns.|Fun|_| [static method]: System.Type -> (System.Type * System.Type) option -TeqCrate.TypePatterns.|Generic|_| [static method]: System.Type -> (System.Type * System.Type list) option -TeqCrate.TypePatterns.|Record|_| [static method]: System.Type -> (System.Reflection.PropertyInfo TeqCrate.TypeField * System.Type) list option -TeqCrate.TypePatterns.|Tuple|_| [static method]: System.Type -> System.Type list option -TeqCrate.TypePatterns.|Union|_| [static method]: System.Type -> Microsoft.FSharp.Reflection.UnionCaseInfo list option -TeqCrate.UnionConvCrate inherit obj -TeqCrate.UnionConvCrate.tryMake [static method]: unit -> 'union TeqCrate.UnionConvCrate option -TeqCrate.UnionConvCrate`1 - interface with 1 member(s) -TeqCrate.UnionConvCrate`1.Apply [method]: TeqCrate.UnionConvEvaluator<'union, 'ret> -> 'ret -TeqCrate.UnionConvEvaluator`2 - interface with 1 member(s) -TeqCrate.UnionConvEvaluator`2.Eval [method]: Microsoft.FSharp.Reflection.UnionCaseInfo TeqCrate.TypeField list -> 'ts HCollections.TypeList -> TeqCrate.Conv<'union, 'ts HCollections.HUnion> -> 'ret \ No newline at end of file +ShapeSifter.ArrayTeqCrate inherit obj +ShapeSifter.ArrayTeqCrate.make [static method]: unit -> 'a [] ShapeSifter.ArrayTeqCrate +ShapeSifter.ArrayTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.ArrayTeqCrate option +ShapeSifter.ArrayTeqCrate`1 - interface with 1 member(s) +ShapeSifter.ArrayTeqCrate`1.Apply [method]: ShapeSifter.ArrayTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.ArrayTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.ArrayTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b []> -> 'ret +ShapeSifter.Conv inherit obj +ShapeSifter.Conv.compose [static method]: ShapeSifter.Conv<'a, 'b> -> ShapeSifter.Conv<'b, 'c> -> ShapeSifter.Conv<'a, 'c> +ShapeSifter.Conv.make [static method]: ('a -> 'b) -> ('b -> 'a) -> ShapeSifter.Conv<'a, 'b> +ShapeSifter.Conv`2 inherit obj +ShapeSifter.Conv`2..ctor [constructor]: ('a -> 'b, 'b -> 'a) +ShapeSifter.Conv`2.From [property]: [read-only] 'b -> 'a +ShapeSifter.Conv`2.get_From [method]: unit -> ('b -> 'a) +ShapeSifter.Conv`2.get_To [method]: unit -> ('a -> 'b) +ShapeSifter.Conv`2.To [property]: [read-only] 'a -> 'b +ShapeSifter.DictionaryTeqCrate inherit obj +ShapeSifter.DictionaryTeqCrate.make [static method]: unit -> System.Collections.Generic.Dictionary<'k, 'v> ShapeSifter.DictionaryTeqCrate +ShapeSifter.DictionaryTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.DictionaryTeqCrate option +ShapeSifter.DictionaryTeqCrate`1 - interface with 1 member(s) +ShapeSifter.DictionaryTeqCrate`1.Apply [method]: ShapeSifter.DictionaryTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.DictionaryTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.DictionaryTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, System.Collections.Generic.Dictionary<'k, 'v>> -> 'ret +ShapeSifter.FunTeqCrate inherit obj +ShapeSifter.FunTeqCrate.make [static method]: unit -> ('a -> 'b) ShapeSifter.FunTeqCrate +ShapeSifter.FunTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.FunTeqCrate option +ShapeSifter.FunTeqCrate`1 - interface with 1 member(s) +ShapeSifter.FunTeqCrate`1.Apply [method]: ShapeSifter.FunTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.FunTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.FunTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b -> 'c> -> 'ret +ShapeSifter.ListTeqCrate inherit obj +ShapeSifter.ListTeqCrate.make [static method]: unit -> 'a list ShapeSifter.ListTeqCrate +ShapeSifter.ListTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.ListTeqCrate option +ShapeSifter.ListTeqCrate`1 - interface with 1 member(s) +ShapeSifter.ListTeqCrate`1.Apply [method]: ShapeSifter.ListTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.ListTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.ListTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b list> -> 'ret +ShapeSifter.MapTeqCrate inherit obj +ShapeSifter.MapTeqCrate.make [static method]: unit -> Map<'k, 'v> ShapeSifter.MapTeqCrate +ShapeSifter.MapTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.MapTeqCrate option +ShapeSifter.MapTeqCrate`1 - interface with 1 member(s) +ShapeSifter.MapTeqCrate`1.Apply [method]: ShapeSifter.MapTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.MapTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.MapTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, Map<'k, 'v>> -> 'ret +ShapeSifter.OptionTeqCrate inherit obj +ShapeSifter.OptionTeqCrate.make [static method]: unit -> 'a option ShapeSifter.OptionTeqCrate +ShapeSifter.OptionTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.OptionTeqCrate option +ShapeSifter.OptionTeqCrate`1 - interface with 1 member(s) +ShapeSifter.OptionTeqCrate`1.Apply [method]: ShapeSifter.OptionTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.OptionTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.OptionTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b option> -> 'ret +ShapeSifter.PairTeqCrate inherit obj +ShapeSifter.PairTeqCrate.make [static method]: unit -> ('a * 'b) ShapeSifter.PairTeqCrate +ShapeSifter.PairTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.PairTeqCrate option +ShapeSifter.PairTeqCrate`1 - interface with 1 member(s) +ShapeSifter.PairTeqCrate`1.Apply [method]: ShapeSifter.PairTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.PairTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.PairTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, ('b * 'c)> -> 'ret +ShapeSifter.Patterns inherit obj +ShapeSifter.Patterns+TType`1 inherit obj, implements 'a ShapeSifter.Patterns+TType System.IEquatable, System.Collections.IStructuralEquatable, 'a ShapeSifter.Patterns+TType System.IComparable, System.IComparable, System.Collections.IStructuralComparable - union type with 1 cases +ShapeSifter.Patterns+TType`1.get_Item [method]: unit -> unit +ShapeSifter.Patterns+TType`1.get_Tag [method]: unit -> int +ShapeSifter.Patterns+TType`1.Item [property]: [read-only] unit +ShapeSifter.Patterns+TType`1.NewTType [static method]: unit -> 'a ShapeSifter.Patterns+TType +ShapeSifter.Patterns+TType`1.Tag [property]: [read-only] int +ShapeSifter.Patterns.tType [static method]: unit -> 'a ShapeSifter.Patterns+TType +ShapeSifter.Patterns.|Array|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.ArrayTeqCrate option +ShapeSifter.Patterns.|Bool|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, bool> option +ShapeSifter.Patterns.|DateTime|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, System.DateTime> option +ShapeSifter.Patterns.|Dictionary|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.DictionaryTeqCrate option +ShapeSifter.Patterns.|Float|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, float> option +ShapeSifter.Patterns.|Fun|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.FunTeqCrate option +ShapeSifter.Patterns.|Int64|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, System.Int64> option +ShapeSifter.Patterns.|Int|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, int> option +ShapeSifter.Patterns.|List|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.ListTeqCrate option +ShapeSifter.Patterns.|Map|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.MapTeqCrate option +ShapeSifter.Patterns.|Option|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.OptionTeqCrate option +ShapeSifter.Patterns.|Pair|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.PairTeqCrate option +ShapeSifter.Patterns.|Record|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.RecordConvCrate option +ShapeSifter.Patterns.|ResizeArray|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.ResizeArrayTeqCrate option +ShapeSifter.Patterns.|Seq|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.SeqTeqCrate option +ShapeSifter.Patterns.|Set|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.SetTeqCrate option +ShapeSifter.Patterns.|String|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, string> option +ShapeSifter.Patterns.|SumOfProducts|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.SumOfProductsConvCrate option +ShapeSifter.Patterns.|Teq|_| [static method]: 'b ShapeSifter.Patterns+TType -> 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, 'b> option +ShapeSifter.Patterns.|TimeSpan|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, System.TimeSpan> option +ShapeSifter.Patterns.|Triple|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.TripleTeqCrate option +ShapeSifter.Patterns.|Tuple|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.TupleConvCrate option +ShapeSifter.Patterns.|Union|_| [static method]: 'a ShapeSifter.Patterns+TType -> 'a ShapeSifter.UnionConvCrate option +ShapeSifter.Patterns.|Unit|_| [static method]: 'a ShapeSifter.Patterns+TType -> TypeEquality.Teq<'a, unit> option +ShapeSifter.RecordConvCrate inherit obj +ShapeSifter.RecordConvCrate.tryMake [static method]: unit -> 'record ShapeSifter.RecordConvCrate option +ShapeSifter.RecordConvCrate`1 - interface with 1 member(s) +ShapeSifter.RecordConvCrate`1.Apply [method]: ShapeSifter.RecordConvEvaluator<'record, 'ret> -> 'ret +ShapeSifter.RecordConvEvaluator`2 - interface with 1 member(s) +ShapeSifter.RecordConvEvaluator`2.Eval [method]: System.Reflection.PropertyInfo ShapeSifter.TypeField list -> 'ts HCollections.TypeList -> ShapeSifter.Conv<'record, 'ts HCollections.HList> -> 'ret +ShapeSifter.Reflection inherit obj +ShapeSifter.Reflection.invokeStaticMethod [static method]: Microsoft.FSharp.Quotations.FSharpExpr -> (System.Type seq -> obj seq -> obj) +ShapeSifter.ResizeArrayTeqCrate inherit obj +ShapeSifter.ResizeArrayTeqCrate.make [static method]: unit -> 'a System.Collections.Generic.List ShapeSifter.ResizeArrayTeqCrate +ShapeSifter.ResizeArrayTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.ResizeArrayTeqCrate option +ShapeSifter.ResizeArrayTeqCrate`1 - interface with 1 member(s) +ShapeSifter.ResizeArrayTeqCrate`1.Apply [method]: ShapeSifter.ResizeArrayTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.ResizeArrayTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.ResizeArrayTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b System.Collections.Generic.List> -> 'ret +ShapeSifter.SeqTeqCrate inherit obj +ShapeSifter.SeqTeqCrate.make [static method]: unit -> 'a seq ShapeSifter.SeqTeqCrate +ShapeSifter.SeqTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.SeqTeqCrate option +ShapeSifter.SeqTeqCrate`1 - interface with 1 member(s) +ShapeSifter.SeqTeqCrate`1.Apply [method]: ShapeSifter.SeqTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.SeqTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.SeqTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b seq> -> 'ret +ShapeSifter.SetTeqCrate inherit obj +ShapeSifter.SetTeqCrate.make [static method]: unit -> 'a Microsoft.FSharp.Collections.FSharpSet ShapeSifter.SetTeqCrate +ShapeSifter.SetTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.SetTeqCrate option +ShapeSifter.SetTeqCrate`1 - interface with 1 member(s) +ShapeSifter.SetTeqCrate`1.Apply [method]: ShapeSifter.SetTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.SetTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.SetTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, 'b Microsoft.FSharp.Collections.FSharpSet> -> 'ret +ShapeSifter.SumOfProductsConvCrate inherit obj +ShapeSifter.SumOfProductsConvCrate.tryMake [static method]: unit -> 'union ShapeSifter.SumOfProductsConvCrate option +ShapeSifter.SumOfProductsConvCrate`1 - interface with 1 member(s) +ShapeSifter.SumOfProductsConvCrate`1.Apply [method]: ShapeSifter.SumOfProductsConvEvaluator<'union, 'ret> -> 'ret +ShapeSifter.SumOfProductsConvEvaluator`2 - interface with 1 member(s) +ShapeSifter.SumOfProductsConvEvaluator`2.Eval [method]: string list -> 'tss HCollections.TypeListList -> ShapeSifter.Conv<'union, 'tss HCollections.SumOfProducts> -> 'ret +ShapeSifter.TripleTeqCrate inherit obj +ShapeSifter.TripleTeqCrate.make [static method]: unit -> ('a * 'b * 'c) ShapeSifter.TripleTeqCrate +ShapeSifter.TripleTeqCrate.tryMake [static method]: unit -> 'a ShapeSifter.TripleTeqCrate option +ShapeSifter.TripleTeqCrate`1 - interface with 1 member(s) +ShapeSifter.TripleTeqCrate`1.Apply [method]: ShapeSifter.TripleTeqEvaluator<'a, 'ret> -> 'ret +ShapeSifter.TripleTeqEvaluator`2 - interface with 1 member(s) +ShapeSifter.TripleTeqEvaluator`2.Eval [method]: TypeEquality.Teq<'a, ('b * 'c * 'd)> -> 'ret +ShapeSifter.Tuple inherit obj +ShapeSifter.Tuple.tryFoldTuple [static method]: 'state HCollections.HListFolder -> 'state -> 'tuple -> 'state option +ShapeSifter.TupleConvCrate inherit obj +ShapeSifter.TupleConvCrate.tryMake [static method]: unit -> 'tuple ShapeSifter.TupleConvCrate option +ShapeSifter.TupleConvCrate`1 - interface with 1 member(s) +ShapeSifter.TupleConvCrate`1.Apply [method]: ShapeSifter.TupleConvEvaluator<'tuple, 'ret> -> 'ret +ShapeSifter.TupleConvEvaluator`2 - interface with 1 member(s) +ShapeSifter.TupleConvEvaluator`2.Eval [method]: 'ts HCollections.TypeList -> ShapeSifter.Conv<'tuple, 'ts HCollections.HList> -> 'ret +ShapeSifter.Type inherit obj +ShapeSifter.Type.print [static method]: System.Type -> string +ShapeSifter.TypeField inherit obj +ShapeSifter.TypeField.attributes [static method]: 'case ShapeSifter.TypeField -> System.Reflection.CustomAttributeData list +ShapeSifter.TypeField.name [static method]: 'case ShapeSifter.TypeField -> string +ShapeSifter.TypeField`1 inherit obj +ShapeSifter.TypeField`1..ctor [constructor]: (string, System.Reflection.CustomAttributeData list, 'case) +ShapeSifter.TypeField`1.Attributes [property]: [read-only] System.Reflection.CustomAttributeData list +ShapeSifter.TypeField`1.get_Attributes [method]: unit -> System.Reflection.CustomAttributeData list +ShapeSifter.TypeField`1.get_Name [method]: unit -> string +ShapeSifter.TypeField`1.get_RawCase [method]: unit -> 'case +ShapeSifter.TypeField`1.Name [property]: [read-only] string +ShapeSifter.TypeField`1.RawCase [property]: [read-only] 'case +ShapeSifter.TypeListCrate - interface with 1 member(s) +ShapeSifter.TypeListCrate.Apply [method]: 'ret ShapeSifter.TypeListEvaluator -> 'ret +ShapeSifter.TypeListCrateModule inherit obj +ShapeSifter.TypeListCrateModule.make [static method]: 'ts HCollections.TypeList -> ShapeSifter.TypeListCrate +ShapeSifter.TypeListCrateModule.makeUntyped [static method]: System.Type list -> ShapeSifter.TypeListCrate +ShapeSifter.TypeListEvaluator`1 - interface with 1 member(s) +ShapeSifter.TypeListEvaluator`1.Eval [method]: 'ts HCollections.TypeList -> 'ret +ShapeSifter.TypeParameterCrate - interface with 1 member(s) +ShapeSifter.TypeParameterCrate.Apply [method]: 'ret ShapeSifter.TypeParameterEvaluator -> 'ret +ShapeSifter.TypeParameterCrateModule inherit obj +ShapeSifter.TypeParameterCrateModule.make [static method]: unit -> ShapeSifter.TypeParameterCrate +ShapeSifter.TypeParameterCrateModule.makeUntyped [static method]: System.Type -> ShapeSifter.TypeParameterCrate +ShapeSifter.TypeParameterCrateModule.toType [static method]: ShapeSifter.TypeParameterCrate -> System.Type +ShapeSifter.TypeParameterEvaluator`1 - interface with 1 member(s) +ShapeSifter.TypeParameterEvaluator`1.Eval [method]: unit -> 'ret +ShapeSifter.TypePatterns inherit obj +ShapeSifter.TypePatterns.|Array|_| [static method]: System.Type -> System.Type option +ShapeSifter.TypePatterns.|Fun|_| [static method]: System.Type -> (System.Type * System.Type) option +ShapeSifter.TypePatterns.|Generic|_| [static method]: System.Type -> (System.Type * System.Type list) option +ShapeSifter.TypePatterns.|Record|_| [static method]: System.Type -> (System.Reflection.PropertyInfo ShapeSifter.TypeField * System.Type) list option +ShapeSifter.TypePatterns.|Tuple|_| [static method]: System.Type -> System.Type list option +ShapeSifter.TypePatterns.|Union|_| [static method]: System.Type -> Microsoft.FSharp.Reflection.UnionCaseInfo list option +ShapeSifter.UnionConvCrate inherit obj +ShapeSifter.UnionConvCrate.tryMake [static method]: unit -> 'union ShapeSifter.UnionConvCrate option +ShapeSifter.UnionConvCrate`1 - interface with 1 member(s) +ShapeSifter.UnionConvCrate`1.Apply [method]: ShapeSifter.UnionConvEvaluator<'union, 'ret> -> 'ret +ShapeSifter.UnionConvEvaluator`2 - interface with 1 member(s) +ShapeSifter.UnionConvEvaluator`2.Eval [method]: Microsoft.FSharp.Reflection.UnionCaseInfo ShapeSifter.TypeField list -> 'ts HCollections.TypeList -> ShapeSifter.Conv<'union, 'ts HCollections.HUnion> -> 'ret \ No newline at end of file diff --git a/ShapeSifter/TeqCrates.fsi b/ShapeSifter/TeqCrates.fsi index 6c8f092..49ad6c1 100644 --- a/ShapeSifter/TeqCrates.fsi +++ b/ShapeSifter/TeqCrates.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System.Collections.Generic open TypeEquality diff --git a/ShapeSifter/Tuple.fsi b/ShapeSifter/Tuple.fsi index a914d11..6f731b3 100644 --- a/ShapeSifter/Tuple.fsi +++ b/ShapeSifter/Tuple.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open HCollections diff --git a/ShapeSifter/Type.fsi b/ShapeSifter/Type.fsi index 6520573..451714d 100644 --- a/ShapeSifter/Type.fsi +++ b/ShapeSifter/Type.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System diff --git a/ShapeSifter/TypeListCrate.fsi b/ShapeSifter/TypeListCrate.fsi index 69cae7c..3e53155 100644 --- a/ShapeSifter/TypeListCrate.fsi +++ b/ShapeSifter/TypeListCrate.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open HCollections open System diff --git a/ShapeSifter/TypeParameterCrate.fsi b/ShapeSifter/TypeParameterCrate.fsi index 1c9c5ed..fdba731 100644 --- a/ShapeSifter/TypeParameterCrate.fsi +++ b/ShapeSifter/TypeParameterCrate.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open System diff --git a/ShapeSifter/TypePatterns.fsi b/ShapeSifter/TypePatterns.fsi index ae9bf19..9565248 100644 --- a/ShapeSifter/TypePatterns.fsi +++ b/ShapeSifter/TypePatterns.fsi @@ -1,4 +1,4 @@ -namespace TeqCrate +namespace ShapeSifter open Microsoft.FSharp.Reflection open System diff --git a/ShapeSifter/version.json b/ShapeSifter/version.json index 32a6b7d..073223b 100644 --- a/ShapeSifter/version.json +++ b/ShapeSifter/version.json @@ -1,7 +1,6 @@ { - "version": "0.2", + "version": "0.3", "publicReleaseRefSpec": [ "^refs/heads/main$" - ], - "pathFilters": null -} \ No newline at end of file + ] +} From f3fc005cac24a8ed9a098f1661ab3324d5d23a4a Mon Sep 17 00:00:00 2001 From: Smaug123 <3138005+Smaug123@users.noreply.github.com> Date: Tue, 28 May 2024 20:28:58 +0100 Subject: [PATCH 4/5] Format --- ShapeSifter.Test/TestPatterns.fs | 12 ++++-------- ShapeSifter.Test/TestSurface.fs | 2 +- ShapeSifter.Test/TestType.fs | 2 +- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/ShapeSifter.Test/TestPatterns.fs b/ShapeSifter.Test/TestPatterns.fs index 757ec6d..e83d2aa 100644 --- a/ShapeSifter.Test/TestPatterns.fs +++ b/ShapeSifter.Test/TestPatterns.fs @@ -32,8 +32,7 @@ module TestPatterns = [] let ``Array active pattern recognises an array`` () = let arr = [| "foo" ; "bar" |] - tryGetArrayLength arr - |> shouldEqual (Some 2) + tryGetArrayLength arr |> shouldEqual (Some 2) let tryGetListLength (xs : 'a) : int option = match tType<'a> with @@ -48,8 +47,7 @@ module TestPatterns = [] let ``List active pattern recognises a list`` () = let xs = [ 1..10 ] - tryGetListLength xs - |> shouldEqual (Some 10) + tryGetListLength xs |> shouldEqual (Some 10) let tryGetMapCount (map : 'a) : int option = match tType<'a> with @@ -64,16 +62,14 @@ module TestPatterns = [] let ``Map active pattern recognises a map`` () = let map = Map.empty |> Map.add "foo" 3 |> Map.add "bar" 12 - tryGetMapCount map - |> shouldEqual (Some 2) + tryGetMapCount map |> shouldEqual (Some 2) [] let ``Tuple active pattern recognises a tuple`` () = let tuple = 5, "hello", false, 8, 2 let sumOfInts = Tuple.tryFoldTuple (HListFolder.makeElementFolder (+)) 0 tuple - sumOfInts - |> shouldEqual (Some 15) + sumOfInts |> shouldEqual (Some 15) [] let ``Fun active pattern recognises a function`` () = diff --git a/ShapeSifter.Test/TestSurface.fs b/ShapeSifter.Test/TestSurface.fs index c2b330c..6191cfa 100644 --- a/ShapeSifter.Test/TestSurface.fs +++ b/ShapeSifter.Test/TestSurface.fs @@ -20,7 +20,7 @@ module TestSurface = let ``Ensure public API is fully documented`` () = DocCoverage.assertFullyDocumented assembly - (* +(* [] let ``Ensure version is monotonic`` () = MonotonicVersion.validate assembly "ShapeSifter" diff --git a/ShapeSifter.Test/TestType.fs b/ShapeSifter.Test/TestType.fs index 6db2921..6e39365 100644 --- a/ShapeSifter.Test/TestType.fs +++ b/ShapeSifter.Test/TestType.fs @@ -26,5 +26,5 @@ module TestType = |> List.map (fun (t, expected) -> [| box t ; box expected |]) [] - [] + [] let ``Test print`` (t : Type, expected : string) : unit = Type.print t |> shouldEqual expected From a613ebeb9a67356884e76340965b6dd0457535a3 Mon Sep 17 00:00:00 2001 From: Smaug123 <3138005+Smaug123@users.noreply.github.com> Date: Tue, 28 May 2024 20:29:33 +0100 Subject: [PATCH 5/5] Disable markdown-link-check --- .github/workflows/dotnet.yaml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/dotnet.yaml b/.github/workflows/dotnet.yaml index 4046570..7d10b89 100644 --- a/.github/workflows/dotnet.yaml +++ b/.github/workflows/dotnet.yaml @@ -131,11 +131,12 @@ jobs: - run: echo "All required checks complete." # This does not gate release, because external dependencies may be flaky. - markdown-link-check: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: gaurav-nelson/github-action-markdown-link-check@v1 + # Disabled while the repo is private + # markdown-link-check: + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - uses: gaurav-nelson/github-action-markdown-link-check@v1 # nuget-publish: # runs-on: ubuntu-latest