Skip to content

Commit

Permalink
tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fc1943s committed Jan 23, 2025
1 parent 3460312 commit 1d0fa9d
Showing 4 changed files with 42 additions and 8 deletions.
4 changes: 2 additions & 2 deletions lib/fsharp/common.py
Original file line number Diff line number Diff line change
@@ -10,7 +10,7 @@

q: str = "\""

def _expr254() -> TypeInfo:
def _expr262() -> TypeInfo:
return union_type("Polyglot.Common.TraceLevel", [], TraceLevel, lambda: [[], [], [], [], []])


@@ -25,7 +25,7 @@ def cases() -> list[str]:
return ["Verbose", "Debug", "Info", "Warning", "Critical"]


TraceLevel_reflection = _expr254
TraceLevel_reflection = _expr262

def to_trace_level(_arg: TraceLevel) -> US0:
if _arg.tag == 1:
34 changes: 33 additions & 1 deletion lib/typescript/fable/build.ps1
Original file line number Diff line number Diff line change
@@ -7,4 +7,36 @@ $ErrorActionPreference = "Stop"
. ../../../scripts/core.ps1


{ dotnet fable --optimize --lang ts --extension .ts --noCache } | Invoke-Block
if (!$fast) {
{ dotnet fable --optimize --lang ts --extension .ts --noCache } | Invoke-Block
{ dotnet fable ../../../deps/Fable/src/fable-library-ts/Fable.Library.TypeScript.fsproj --lang ts --extension .ts --noCache } | Invoke-Block
}

$paths = @(
"../../../deps/Fable/src/fable-library-ts/Array.ts",
"../../../deps/Fable/src/fable-library-ts/Seq.ts",
"../../../deps/Fable/src/fable-library-ts/Choice.ts",
"../../../deps/Fable/src/fable-library-ts/FSharp.Collections.ts",
"../../../deps/Fable/src/fable-library-ts/FSharp.Core.CompilerServices.ts",
"../../../deps/Fable/src/fable-library-ts/FSharp.Core.ts",
"../../../deps/Fable/src/fable-library-ts/Global.ts",
"../../../deps/Fable/src/fable-library-ts/List.ts",
"../../../deps/Fable/src/fable-library-ts/Map.ts",
"../../../deps/Fable/src/fable-library-ts/MutableMap.ts",
"../../../deps/Fable/src/fable-library-ts/MutableSet.ts",
"../../../deps/Fable/src/fable-library-ts/Native.ts",
"../../../deps/Fable/src/fable-library-ts/Random.ts",
"../../../deps/Fable/src/fable-library-ts/Range.ts",
"../../../deps/Fable/src/fable-library-ts/Result.ts",
"../../../deps/Fable/src/fable-library-ts/Seq2.ts",
"../../../deps/Fable/src/fable-library-ts/Set.ts",
"../../../deps/Fable/src/fable-library-ts/System.Collections.Generic.ts",
"../../../deps/Fable/src/fable-library-ts/System.Text.ts",
"../../../deps/Fable/src/fable-library-ts/SystemException.ts"
)

foreach ($path in $paths) {
(Get-Content $path) `
-replace "`"\./fable_modules/fable-library-ts\.[\-\w\d\.]+/", "`"./" `
| Set-Content $path
}
2 changes: 1 addition & 1 deletion scripts/dep_dotnet-interactive.ps1
Original file line number Diff line number Diff line change
@@ -49,5 +49,5 @@ if (!$fast) {
Copy-Item "../deps/dotnet-interactive/artifacts/bin/dotnet-interactive/Release/net9.0/**" $netVersion -Recurse -Force

if ($pack) {
{ dotnet pack -c Release /p:Version=0.1.2 } | Invoke-Block -Location ../deps/dotnet-interactive/src/dotnet-interactive -EnvironmentVariables @{ "MSBUILDDISABLENODEREUSE" = "1" }
{ dotnet pack -c Release /p:Version=0.1.3 } | Invoke-Block -Location ../deps/dotnet-interactive/src/dotnet-interactive -EnvironmentVariables @{ "MSBUILDDISABLENODEREUSE" = "1" }
}
10 changes: 6 additions & 4 deletions scripts/dep_dotnet-interactive_extension.ps1
Original file line number Diff line number Diff line change
@@ -8,10 +8,6 @@ $ErrorActionPreference = "Stop"
. ../deps/spiral/lib/spiral/lib.ps1


if (!$fast) {
{ dotnet fable ../deps/Fable/src/fable-library-ts/Fable.Library.TypeScript.fsproj --lang typescript --extension .ts } | Invoke-Block
}

$interactivePath = "../deps/dotnet-interactive"

$extensionSrcPath = "$interactivePath/src/polyglot-notebooks-vscode-insiders"
@@ -109,6 +105,12 @@ if (Test-Path $extensionsPathHome) {
$extensionsPath += $extensionsPathHome
}

$extensionsPathHome = "$HOME/.vscode-remote/extensions"

if (Test-Path $extensionsPathHome) {
$extensionsPath += $extensionsPathHome
}

if ($IsWindows -and $env:scoop) {
$extensionsPathScoop = "$env:scoop/persist/vscode/data/extensions"
if (Test-Path $extensionsPathScoop) {

0 comments on commit 1d0fa9d

Please sign in to comment.