Donate Share

NUnit .Net unit testing framework

Tracker: Bugs

5 System.IO.DirectoryNotFoundException after Add VS Project - ID: 1569967
Last Update: Comment added ( charliepoole )

Context:
- .NET Framework 2.0.
- NUnit GUI with Visual Studio support enabled.
- Using Visual Studio 2005 projects.
- Existing .nunit project file for existing solution.

Steps to reproduce:
1. Add new unit testing class library to existing
solution. Include at least one test fixture and test
case. Build the solution in Debug mode *only*.
1. Start NUnit GUI.
2. File > New Project
3. Save new project.
4. Menu Project > Add VS Project
5. Add the project from step 1.

Expected result:
- No error, project is added.

Actual result:
Step: add unit testing project
System.IO.DirectoryNotFoundException... Could not find
a part of the path
'<fullPathToProjectDirectoryWasHere>\bin\Release'.

Server stack trace:
at System.IO.__Error.WinIOError(Int32 errorCode,
String maybeFullPath)
at System.IO.Directory.SetCurrentDirectory(String path)
at NUnit.Core.DirectorySwapper..ctor(String
directoryName)
at
NUnit.Core.Builders.TestAssemblyBuilder.Load(String
assemblyName)
at NUnit.Core.Builders.TestAssemblyBuilder.Build()
at
NUnit.Core.Builders.TestAssemblyBuilder.Build(String
testName)
at NUnit.Core.TestSuiteBuilder.Build(String
projectName, String[] assemblies, String testName)
at NUnit.Core.SimpleTestRunner.Load(String
projectName, String[] assemblies, String testName)
at NUnit.Core.ProxyTestRunner.Load(String
projectName, String[] assemblies, String testName)
at NUnit.Core.ProxyTestRunner.Load(String
projectName, String[] assemblies, String testName)
at
System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(I
ntPtr
md, Object[] args, Object server, Int32 methodPtr,
Boolean fExecuteInContext, Object[]& outArgs)
at
System.Runtime.Remoting.Messaging.StackBuilderSink.PrivateProcessMessage(Ru
ntimeMethodHandle
md, Object[] args, Object server, Int32 methodPtr,
Boolean fExecuteInContext, Object[]& outArgs)
at
System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMess
age
msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [0]:
at
System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage
reqMsg, IMessage retMsg)
at
System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData&
msgData, Int32 type)
at NUnit.Core.TestRunner.Load(String projectName,
String[] assemblies, String testName)
at NUnit.Util.TestDomain.Load(NUnitProject project,
String testName)
at NUnit.Util.TestLoader.LoadTest(String testName)

Variations:
- Create new unit testing project and never build, only
save. Both the bin\Debug and bin\Release folders won't
exist.

Workaround:
- Make sure solution was built in Debug and Release
mode once before adding to NUnit solution.


Bernard Vander Beken ( jawn ) - 2006-10-03 13:17

5

Closed

Fixed

Charlie Poole

nunit-gui

V2.2.8 - No Longer Accepted

Public


Comment ( 1 )

Date: 2006-11-16 22:20
Sender: charliepooleProject Admin


Fixed in 2.4. Not fixing in 2.2.x.


Attached File

No Files Currently Attached

Changes ( 4 )

Field Old Value Date By
status_id Open 2006-11-16 22:20 charliepoole
resolution_id None 2006-11-16 22:20 charliepoole
assigned_to nobody 2006-11-16 22:20 charliepoole
close_date - 2006-11-16 22:20 charliepoole