I tried Xamarin (on Mac OS X) to do cross-platform (Mac, iOS, Android) development in Mono. I created the "Point" class inside the "Filament" namespace, and now I'm trying to add unit tests.
In the Mono world, there are two approaches to unit testing: NUnit and NUnitLite. I tried both (in the latter case, following this tutorial ), with the same result:
In my unit test project, I add a link to the Point.cs file (by right-clicking the project, using "Add ...", selecting the file, and then selecting the "Add as link" option). In my unit test file (PointTest.cs) I add "Using Filament"; at the top of the file. But, despite the fact that now I can use the Point class, and it compiles successfully, Intellisense seems completely oblivious to this - every time I start typing โPointโ, it expands it to โPointTestโ, and when I stubbornly changing it to Point, he draws it red as an error.
In fact, the same problem occurred on my โuseโ line; I typed "Using Filament" and changed it to "using FilamentTestsiOS" (the namespace of my unit test project).
It drives me crazy ... but as a complete noob for Mono, Xamarin, NUnit, and NUnitLite, I'm sure I'm doing something stupid.
What is the right way to configure C # / Mono unit test so that both intellisense and the compiler recognize the classes for which I am writing tests?
source share