Cannot run nunit tests with Nant
问题 I'm trying to launch nunit ui tests with nant and get the error: Buildfile: file:///c:/UItests/nant.build Target framework: Microsoft .NET Framework 4.0 Target(s) specified: build build: [nunit2] 2012/06/20/13:29:52: Exception in set up method: The CurrentThread needs to have it's ApartmentState set to Apar tmentState.STA to be able to automate Internet Explorer. [nunit2] 2012/06/20/13:29:52: Exception in set up method: The CurrentThread needs to have it's ApartmentState set to Apar