Question

I am trying to use a Suite Configuration File with FitSharp. I am use the exact format that this page lays out, however, every time I try to access it, I get the following error:

fitSharp.Machine.Exception.TypeMissingException: Type 'AppDomainSetup' not found in assemblies:
    file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll
    file:///C:/Apps/FitSharp/4.0/Runner.exe
    file:///C:/Apps/FitSharp/4.0/fitSharp.DLL
    file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
    file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
    file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
    file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll

   at fitSharp.Machine.Engine.ApplicationUnderTest.FindType(NameMatcher typeName)
   at fitSharp.Machine.Engine.TypeDictionary.GetItem(String typeName)
   at fitSharp.Machine.Application.SuiteConfiguration.LoadNode(String typeName, XmlNode methodNode)
   at fitSharp.Machine.Application.SuiteConfiguration.LoadXml(String configurationXml)
   at fitSharp.Machine.Application.ArgumentParser.InvokeArgumentHandler(String switch, String argumentValue)
   at fitSharp.Machine.Application.ArgumentParser.Parse(IList`1 commandLineArguments)
   at fitSharp.Machine.Application.Shell.Run(IList`1 commandLineArguments)

It appears that AppDomainSetup is not a valid tag for a suite config, but that cannot be since it is used in that example.

What is going on? How would I correct this issue? My ultimate goal is to use two config files for the testing fixtures. I need to use both an App.config and a wse3policyCache.config.

Here is my Suite Config

<suiteConfig>
  <AppDomainSetup>
    <ApplicationBase>App</ApplicationBase>
    <ConfigurationFile>D:\Projects\pathto\myproject\app.config</ConfigurationFile>
  </AppDomainSetup>
  <ApplicationUnderTest>
    <AddAssembly>D:\Projects\pathto\myproject\bin\Debug\myproject.dll</AddAssembly>
    <AddNamespace>myproject.Namespace</AddNamespace>
  </ApplicationUnderTest>
  <Culture>
    <Name>en-AU</Name>
  </Culture>
  <Settings>
    <Runner>fitSharp.Slim.Service.Runner</Runner>
  </Settings>
  <FileExclusions>
  </FileExclusions>
  <Slim.Operators>
  </Slim.Operators>
  <Fit.Operators>
    <Add>my.Custom.Handler</Add>
    <Remove>fit.Operators.ExecuteError</Remove>
  </Fit.Operators>
</suiteConfig>

And here is the beginning of the Fitnesse Test page that I am using

!define TEST_SYSTEM {slim}
!define COMMAND_PATTERN {%m -c suite.config %p}
!define TEST_RUNNER {C:\Apps\FitSharp\4.0\Runner.exe}

!path D:\Projects\pathto\myproject\bin\Debug\myproject.dll

!define COLLAPSE_SETUP {true}
!define COLLAPSE_TEARDOWN {true}
Was it helpful?

Solution

The issue is that the documentation is not completely accurate. AppDomainSetup must be be fully qualified as

<System.AppDomainSetup>

Thanks to the guys over at this forum post for helping me out.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top