[Mono-list] NUnit examples, Mono1.9.1, no suitable entry point error

Alan McGovern alan.mcgovern at gmail.com
Sun Aug 24 00:18:31 EDT 2008


To get rid of the compile error, just compile the .cs files as a library. I
think the syntax is: --target:library

Alan.

On 8/24/08, Charlie Poole <charlie at nunit.com> wrote:
>
> When you run your program, it does exactly what you
> told it to do, i.e. { } :-)
>
> To run NUnit tests, you execute NUnit, not the tests.
> You can run
>   nunit-console mytests.dll
>   nunit mytests.dll
> OR nunit and then open the test assembly from the menu.
>
> Charlie
>
> > -----Original Message-----
> > From: mono-list-bounces at lists.ximian.com
> > [mailto:mono-list-bounces at lists.ximian.com] On Behalf Of cknell
> > Sent: Tuesday, August 19, 2008 12:46 PM
> > To: mono-list at lists.ximian.com
> > Subject: [Mono-list] NUnit examples, Mono1.9.1, no suitable
> > entry point error
> >
> >
> > I've recently downloaded Mono 1.9.1 and NUnit 2.4.8. I have a
> > number of examples of basic unit tests collected from a
> > variety of sources. That's what you do when the one you have
> > won't work, you look for another. When compiling the
> > examples, I invariably get an error from Mono:
> >
> > "error CS5001: Program 'fill in the blank' does not contain a
> > static 'Main'
> > method suitable for an entry point"
> >
> > Now, as a sometime Java programmer, I have a superficial
> > understanding of the message. If I insert a line like this:
> >
> > public static void Main(){}
> >
> > the program compiles. But when I run the compiled program, I
> > get neither an error, nor the expected response. I surmise
> > that is because when I run the program, the Main() method is
> > being called and the actual method I want to run is being ignored.
> >
> > Can anyone give me guidance on this?
> >
> > Thanks.
> > --
> > View this message in context:
> > http://www.nabble.com/NUnit-examples%2C-Mono1.9.1%2C-no-suitab
> > le-entry-point-error-tp19057246p19057246.html
> > Sent from the Mono - General mailing list archive at Nabble.com.
> >
> > _______________________________________________
> > Mono-list maillist  -  Mono-list at lists.ximian.com
> > http://lists.ximian.com/mailman/listinfo/mono-list
> >
>
>
>
> _______________________________________________
> Mono-list maillist  -  Mono-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-list/attachments/20080824/b572adf1/attachment-0001.html 


More information about the Mono-list mailing list