simple-binary-encoding
simple-binary-encoding copied to clipboard
[C#] Overhal unit testing state
As mentioned in the discussion for another PR there are some issues with the current state of sbe-dll unit tests, to summerise what I'm seeing and what @ZachBray mentioned:
- I can't get tests to run on Linux (possible because of MS test frameowrk? not sure why)
- Tests aren't targeting netcoreapp2.1/2.0 at all, so not .NET Core testing isn't happening
- Tests are targeting net45 as of now, which doesn't officially support the .NET framework that is the minimal requirement for sbe-dll.dll which is targeting netstandard2.0.
- tests are not run as part of the gradle build at all, AFAICT gradle only generates the csharp source code from sbe schema with no
dotnet buildbeing invoked at all, so I think, we probably want separate I think we would/should want tests to be able to run on an OS (Linux+Windows), using the standard toolset (e.g.dotnet test) from the travis build script
If that requires porting tests to NUnit/XUnit, let's make that call (though I admit I can't find anywhere saying MSTest won't work on Linux, I just can't get it to run right now).
Any thoughts about this?
I'd like to target both netstandard2.0 and .NET framework 4.5 so we can support vanilla Server2k12 without service packs. The current nuget package suports both.
The tests are definitely lagging and I would like to see them also build for both and supporting linux is also desirable. I think there are some ways to wrap mstest for linux but they don't look very good and I would be happy to use some other test framework if it made this easier. I'm not sufficiently familiar with the mono tool set to know what's right here.
The gradle integration is a little weak and could be expanded but it needs to check for the presence for dotnet before doing anything as the rust does,
Basically, this is all stuff I'd like to see improved.
Just one note, you cannot target tests to run on netstandard, you have to target framework/core.
The version being tested can be the netstandard version of course...