Closed teknikal-wizard closed 2 years ago
@isaacabraham
I don't think this is related to the issue you linked - the [<EntryPoint>]
attribute is there and has been before the changes.
To me it seems that there's some issue with todos
ResizeArray not being initialised for some reason.
Anyway thanks for noticing that - needs to be fixed before we release next template version.
:+1: for adding unit tests to CI - see #493
EDIT:
The [<EntryPoint>]
is indeed necessary, but not for tests project but rather server:
[<EntryPoint>]
let main _ =
run app
0
Above fixes the issue.
Related SO Thread
If I were to choose, I'd revert back to the class approach, but that's just me :)
I was told yesterday on Slack that upgrading the tests project to .NET 6 fixes the issue as well, and that someone is working on an update. I haven't tried this myself though yet.
If I were to choose, I'd revert back to the class approach, but that's just me :)
Is that just because of this issue or other reasons?
Currently the Server test throws a null reference exception when adding a Todo.
I believe this is due to a known F# issue
We could add an explicit entry point or revert to using a class for the Storage instead of a module?
I also think this, along with the broken tests when the class was first replaced with a module, are a strong case for us running the content unit tests in the CI pipeline in addition to the template ones.