Skip to content

Commit

Permalink
Fix .dll missing types
Browse files Browse the repository at this point in the history
- PSFzf.dll is no longer missing ReverseLineReader
- add back unit test to make sure type loads
  • Loading branch information
kelleyma49 committed Mar 1, 2020
1 parent a15e55d commit 0879d47
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
9 changes: 8 additions & 1 deletion .github/scripts/Build.ps1
Original file line number Diff line number Diff line change
@@ -1,2 +1,9 @@
$ErrorActionPreference = "Stop"

$env:DOTNET_CLI_TELEMETRY_OPTOUT=1
dotnet build --configuration Release --output . .\PSFzf-Binary\PSFzf-Binary.csproj
dotnet build --configuration Release PSFzf.sln
$dllPaths = Get-ChildItem PSFzf.dll -Recurse
if ($null -eq $dllPaths) {
throw 'Unable to find PSFzf.dll'
}
Copy-Item $dllPaths[0].FullName . -Force -Verbose
13 changes: 13 additions & 0 deletions PSFzf.tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,19 @@ Describe "Find-CurrentPath" {
}
}

Describe "Add-BinaryModuleTypes" {
InModuleScope PsFzf {
Context "Module Loaded" {
It "Be Able to Create Type" {
$filePath = Join-Path ([system.io.path]::GetTempPath()) 'TestFile.txt'
1..100 | Add-Content $filePath
$newObject = New-Object PSFzf.IO.ReverseLineReader -ArgumentList $filePath
$newObject | Should Not Be $null
}
}
}
}

# CI seems to have problems on GitHub CI - timing issues?
if ( $false ) {

Expand Down

0 comments on commit 0879d47

Please sign in to comment.