Skip to content

Commit 9d61ee7

Browse files
committed
update tfms for type providers
1 parent c15c030 commit 9d61ee7

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

tests/FSharp.Compiler.UnitTests/ProductVersion.fs

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -93,21 +93,21 @@ module TypeProviderDesignTimeComponentLoading =
9393
let ``check tooling paths for type provider design time component loading`` () =
9494
let expected =
9595
[
96-
#if NET46 // only available on net46
97-
Path.Combine("typeproviders", "fsharp41", "net461")
98-
Path.Combine("tools", "fsharp41", "net461")
99-
Path.Combine("typeproviders", "fsharp41", "net452")
100-
Path.Combine("tools", "fsharp41", "net452")
101-
Path.Combine("typeproviders", "fsharp41", "net451")
102-
Path.Combine("tools", "fsharp41", "net451")
103-
Path.Combine("typeproviders", "fsharp41", "net45")
104-
Path.Combine("tools", "fsharp41", "net45")
105-
#else // only available on netcoreapp2.0
106-
Path.Combine("typeproviders", "fsharp41", "netcoreapp2.0")
107-
Path.Combine("tools", "fsharp41", "netcoreapp2.0")
108-
#endif // available in both
109-
Path.Combine("typeproviders", "fsharp41", "netstandard2.0")
110-
Path.Combine("tools", "fsharp41", "netstandard2.0")
96+
#if NET46
97+
// only searched when executing on .NET Framework
98+
for tfm in ["net48"; "net472"; "net471"; "net47"; "net462"; "net461"; "net452"; "net451"; "net45"] do
99+
yield Path.Combine("typeproviders", "fsharp41", tfm)
100+
yield Path.Combine("tools", "fsharp41", tfm)
101+
#else
102+
// only searched when executing on .NET Core
103+
for tfm in ["netcoreapp2.1"; "netcoreapp2.0"] do
104+
yield Path.Combine("typeproviders", "fsharp41", tfm)
105+
yield Path.Combine("tools", "fsharp41", tfm)
106+
#endif
107+
// always searched
108+
for tfm in ["netstandard2.0"] do
109+
yield Path.Combine("typeproviders", "fsharp41", tfm)
110+
yield Path.Combine("tools", "fsharp41", tfm)
111111
]
112112
let actual = FSharp.Compiler.ExtensionTyping.toolingCompatiblePaths()
113113
printfn "actual = %A" actual

0 commit comments

Comments
 (0)