Browse Source

Fix unit tests.

newNRvisualizers
Daniel Grunwald 13 years ago
parent
commit
46a0fda1ae
  1. 2
      src/AddIns/Analysis/UnitTesting/Test/NUnit/NUnitTestFrameworkIsTestProjectTests.cs
  2. 3
      src/Main/Base/Test/SDTestFixtureBase.cs
  3. 2
      src/Main/Base/Test/StringTagProvider/NullProjectStringTagProviderTestFixture.cs

2
src/AddIns/Analysis/UnitTesting/Test/NUnit/NUnitTestFrameworkIsTestProjectTests.cs

@ -23,7 +23,9 @@ namespace UnitTesting.Tests.NUnit @@ -23,7 +23,9 @@ namespace UnitTesting.Tests.NUnit
public void Init()
{
SD.InitializeForUnitTests();
SD.Services.AddService(typeof(IMessageLoop), MockRepository.GenerateStrictMock<IMessageLoop>());
SD.Services.AddService(typeof(IParserService), MockRepository.GenerateStrictMock<IParserService>());
SD.MainThread.Stub(m => m.VerifyAccess());
testFramework = new NUnitTestFramework();
}

3
src/Main/Base/Test/SDTestFixtureBase.cs

@ -3,6 +3,7 @@ @@ -3,6 +3,7 @@
using System;
using NUnit.Framework;
using Rhino.Mocks;
namespace ICSharpCode.SharpDevelop
{
@ -16,6 +17,8 @@ namespace ICSharpCode.SharpDevelop @@ -16,6 +17,8 @@ namespace ICSharpCode.SharpDevelop
public virtual void FixtureSetUp()
{
SD.InitializeForUnitTests();
SD.Services.AddService(typeof(IMessageLoop), MockRepository.GenerateStrictMock<IMessageLoop>());
SD.MainThread.Stub(m => m.VerifyAccess());
}
[TestFixtureTearDown]

2
src/Main/Base/Test/StringTagProvider/NullProjectStringTagProviderTestFixture.cs

@ -12,7 +12,7 @@ namespace ICSharpCode.SharpDevelop.Tests.StringTagProvider @@ -12,7 +12,7 @@ namespace ICSharpCode.SharpDevelop.Tests.StringTagProvider
/// Tests the SharpDevelopStringTagProvider when there is no active project.
/// </summary>
[TestFixture]
public class NullProjectStringTagProviderTestFixture
public class NullProjectStringTagProviderTestFixture : SDTestFixtureBase
{
SharpDevelopStringTagProvider tagProvider;

Loading…
Cancel
Save