Skip to content

Commit

Permalink
Fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
TimLariviere committed Jan 16, 2024
1 parent 9ed734a commit be6e352
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
</PropertyGroup>

<ItemGroup>
<PackageVersion Include="Fabulous" Version="2.5.0-pre2" />
<PackageVersion Include="Fabulous" Version="2.5.0-pre3" />
<PackageVersion Include="FsCheck.NUnit" Version="2.16.6" />
<PackageVersion Include="FSharp.Core" Version="8.0.100" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.7.2" />
Expand Down
9 changes: 4 additions & 5 deletions src/Fabulous.MauiControls.Tests/WidgetTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,14 @@ type WidgetTests() =
let treeContext: ViewTreeContext =
{ CanReuseView = MauiViewHelpers.canReuseView
GetViewNode = ViewNode.get
Logger = ProgramHelpers.defaultLogger()
Dispatch = dispatch }

let envContext = new EnvironmentContext()
Logger = ProgramDefaults.defaultLogger()
Dispatch = dispatch
GetComponent = Component.get }

let navPage = FabNavigationPage()
let weakRef = WeakReference(navPage)

let node = ViewNode(None, treeContext, envContext, weakRef)
let node = ViewNode(None, treeContext, weakRef)

Reconciler.update treeContext.CanReuseView ValueNone (oldWidget.Compile()) node
Reconciler.update treeContext.CanReuseView (ValueSome(oldWidget.Compile())) (newWidget.Compile()) node
Expand Down

0 comments on commit be6e352

Please sign in to comment.