-
Notifications
You must be signed in to change notification settings - Fork 648
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4,492 changed files
with
361,403 additions
and
238,923 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
# Auto detect text files and perform CRLF normalization | ||
* text=auto eol=crlf | ||
|
||
# Standard to msysgit | ||
*.doc diff=astextplain | ||
*.DOC diff=astextplain | ||
*.docx diff=astextplain | ||
*.DOCX diff=astextplain | ||
*.dot diff=astextplain | ||
*.DOT diff=astextplain | ||
*.pdf diff=astextplain | ||
*.PDF diff=astextplain | ||
*.rtf diff=astextplain | ||
*.RTF diff=astextplain | ||
|
||
*.exe -text -diff | ||
*.jpg -text -diff | ||
*.png -text -diff | ||
*.gif -text -diff | ||
*.dll -text -diff | ||
*.pdb -text -diff | ||
*.pptx -text -diff | ||
*.xap -text -diff | ||
*.ico -text -diff | ||
|
||
*.cs text diff=csharp | ||
*.config text diff=csharp | ||
*.xml text diff=csharp | ||
*.vb text | ||
*.c text | ||
*.cpp text | ||
*.cxx text | ||
*.h text | ||
*.hxx text | ||
*.py text | ||
*.rb text | ||
*.java text | ||
*.html text | ||
*.htm text | ||
*.css text | ||
*.scss text | ||
*.sass text | ||
*.less text | ||
*.js text | ||
*.lisp text | ||
*.clj text | ||
*.sql text | ||
*.php text | ||
*.lua text | ||
*.m text | ||
*.asm text | ||
*.erl text | ||
*.fs text | ||
*.fsx text | ||
*.hs text | ||
|
||
*.psm1 text | ||
*.ps1 text | ||
*.txt text eol=crlf | ||
*.bat text eol=crlf | ||
|
||
# Custom for Visual Studio | ||
*.csproj merge=union | ||
*.vbproj merge=union | ||
*.fsproj merge=union | ||
*.dbproj merge=union | ||
*.sln text eol=crlf merge=union | ||
*.suo -text -diff | ||
*.snk -text -diff | ||
*.cub -text -diff | ||
*.wixlib -text -diff |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,31 @@ | ||
build | ||
binaries | ||
obj | ||
bin | ||
.nu | ||
_ReSharper.* | ||
_UpgradeReport.* | ||
*.csproj.user | ||
*.resharper.user | ||
*.resharper | ||
*.suo | ||
*.cache | ||
*~ | ||
*.swp | ||
*.user | ||
TestResult.xml | ||
results | ||
CommonAssemblyInfo.cs | ||
lib/sqlite/System.Data.SQLite.dll | ||
*.orig | ||
Samples/DataBus/storage | ||
packages | ||
PrecompiledWeb | ||
core-only | ||
Release | ||
Artifacts | ||
csx | ||
build | ||
build32 | ||
binaries | ||
obj | ||
bin | ||
.nu | ||
_ReSharper.* | ||
_UpgradeReport.* | ||
*.csproj.user | ||
*.resharper.user | ||
*.resharper | ||
*.suo | ||
*.cache | ||
*~ | ||
*.swp | ||
*.user | ||
TestResult.xml | ||
results | ||
CommonAssemblyInfo.cs | ||
lib/sqlite/System.Data.SQLite.dll | ||
*.orig | ||
Samples/DataBus/storage | ||
packages | ||
PrecompiledWeb | ||
core-only | ||
Release | ||
Artifacts | ||
LogFiles | ||
csx | ||
*.ncrunchproject | ||
_NCrunch_NServiceBus/* |
22 changes: 22 additions & 0 deletions
22
AcceptanceTests/NServiceBus.AcceptanceTesting/Customization/Conventions.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
namespace NServiceBus.AcceptanceTesting.Customization | ||
{ | ||
using System; | ||
using Support; | ||
|
||
public class Conventions | ||
{ | ||
static Conventions() | ||
{ | ||
EndpointNamingConvention = (t) => t.Name; | ||
} | ||
|
||
public static Func<RunDescriptor> DefaultRunDescriptor = () => new RunDescriptor {Key = "Default"}; | ||
|
||
public static Func<Type, string> EndpointNamingConvention { get; set; } | ||
|
||
public static string DefaultNameFor<T>() | ||
{ | ||
return EndpointNamingConvention(typeof(T)); | ||
} | ||
} | ||
} |
143 changes: 143 additions & 0 deletions
143
AcceptanceTests/NServiceBus.AcceptanceTesting/EndpointConfigurationBuilder.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,143 @@ | ||
namespace NServiceBus.AcceptanceTesting | ||
{ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Threading; | ||
using Support; | ||
|
||
public class EndpointConfigurationBuilder : IEndpointConfigurationFactory | ||
{ | ||
public EndpointConfigurationBuilder() | ||
{ | ||
configuration.EndpointMappings = new Dictionary<Type, Type>(); | ||
} | ||
|
||
|
||
public EndpointConfigurationBuilder AuditTo<T>() | ||
{ | ||
configuration.AuditEndpoint = typeof(T); | ||
|
||
return this; | ||
} | ||
public EndpointConfigurationBuilder AuditTo(Address addressOfAuditQueue) | ||
{ | ||
configuration.AddressOfAuditQueue = addressOfAuditQueue; | ||
|
||
return this; | ||
} | ||
|
||
public EndpointConfigurationBuilder CustomMachineName(string customMachineName) | ||
{ | ||
configuration.CustomMachineName = customMachineName; | ||
|
||
return this; | ||
} | ||
|
||
public EndpointConfigurationBuilder CustomEndpointName(string customEndpointName) | ||
{ | ||
configuration.CustomEndpointName = customEndpointName; | ||
|
||
return this; | ||
} | ||
|
||
|
||
public EndpointConfigurationBuilder AppConfig(string path) | ||
{ | ||
configuration.AppConfigPath = path; | ||
|
||
return this; | ||
} | ||
|
||
|
||
public EndpointConfigurationBuilder AddMapping<T>(Type endpoint) | ||
{ | ||
this.configuration.EndpointMappings.Add(typeof(T),endpoint); | ||
|
||
return this; | ||
} | ||
|
||
EndpointConfiguration CreateScenario() | ||
{ | ||
configuration.BuilderType = GetType(); | ||
|
||
return this.configuration; | ||
} | ||
|
||
public EndpointConfigurationBuilder EndpointSetup<T>() where T : IEndpointSetupTemplate | ||
{ | ||
return EndpointSetup<T>(c => { }); | ||
} | ||
|
||
public EndpointConfigurationBuilder EndpointSetup<T>(Action<Configure> configCustomization) where T: IEndpointSetupTemplate | ||
{ | ||
configuration.GetConfiguration = (settings,routingTable) => | ||
{ | ||
var config = ((IEndpointSetupTemplate)Activator.CreateInstance<T>()).GetConfiguration(settings, configuration, new ScenarioConfigSource(configuration, routingTable)); | ||
configCustomization(config); | ||
return config; | ||
}; | ||
|
||
return this; | ||
} | ||
|
||
EndpointConfiguration IEndpointConfigurationFactory.Get() | ||
{ | ||
return CreateScenario(); | ||
} | ||
|
||
public class SubscriptionsSpy : IAuthorizeSubscriptions | ||
{ | ||
private readonly ManualResetEvent manualResetEvent = new ManualResetEvent(false); | ||
private int subscriptionsReceived; | ||
|
||
public int NumberOfSubscriptionsToWaitFor { get; set; } | ||
|
||
public bool AuthorizeSubscribe(string messageType, string clientEndpoint, | ||
IDictionary<string, string> headers) | ||
{ | ||
if (Interlocked.Increment(ref subscriptionsReceived) >= NumberOfSubscriptionsToWaitFor) | ||
{ | ||
manualResetEvent.Set(); | ||
} | ||
|
||
return true; | ||
} | ||
|
||
public bool AuthorizeUnsubscribe(string messageType, string clientEndpoint, | ||
IDictionary<string, string> headers) | ||
{ | ||
return true; | ||
} | ||
|
||
public void Wait() | ||
{ | ||
if(!manualResetEvent.WaitOne(TimeSpan.FromSeconds(20))) | ||
throw new Exception("No subscription message was received"); | ||
|
||
} | ||
} | ||
|
||
|
||
readonly EndpointConfiguration configuration = new EndpointConfiguration(); | ||
|
||
public EndpointConfigurationBuilder WithConfig<T>(Action<T> action) | ||
{ | ||
var config = Activator.CreateInstance<T>(); | ||
|
||
action(config); | ||
|
||
configuration.UserDefinedConfigSections[typeof (T)] = config; | ||
|
||
return this; | ||
} | ||
|
||
public EndpointConfigurationBuilder ExcludeType<T>() | ||
{ | ||
configuration.TypesToExclude.Add(typeof(T)); | ||
|
||
return this; | ||
} | ||
} | ||
} |
78 changes: 78 additions & 0 deletions
78
AcceptanceTests/NServiceBus.AcceptanceTesting/NServiceBus.AcceptanceTesting.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProjectGuid>{758357F6-CD31-4337-80C4-BA377FC257AF}</ProjectGuid> | ||
<OutputType>Library</OutputType> | ||
<AppDesignerFolder>Properties</AppDesignerFolder> | ||
<RootNamespace>NServiceBus.AcceptanceTesting</RootNamespace> | ||
<AssemblyName>NServiceBus.AcceptanceTesting</AssemblyName> | ||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> | ||
<FileAlignment>512</FileAlignment> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Debug\</OutputPath> | ||
<DefineConstants>DEBUG;TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Release\</OutputPath> | ||
<DefineConstants>TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Reference Include="NServiceBus"> | ||
<HintPath>..\..\binaries\NServiceBus.dll</HintPath> | ||
</Reference> | ||
<Reference Include="NServiceBus.Core"> | ||
<HintPath>..\..\binaries\NServiceBus.Core.dll</HintPath> | ||
</Reference> | ||
<Reference Include="System" /> | ||
<Reference Include="System.Configuration" /> | ||
<Reference Include="System.Core" /> | ||
<Reference Include="System.Xml.Linq" /> | ||
<Reference Include="System.Data.DataSetExtensions" /> | ||
<Reference Include="Microsoft.CSharp" /> | ||
<Reference Include="System.Data" /> | ||
<Reference Include="System.Xml" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="Customization\Conventions.cs" /> | ||
<Compile Include="Properties\AssemblyInfo.cs" /> | ||
<Compile Include="Support\ActiveRunner.cs" /> | ||
<Compile Include="ScenarioContext.cs" /> | ||
<Compile Include="Support\EndpointBehaviour.cs" /> | ||
<Compile Include="Support\BehaviourFactory.cs" /> | ||
<Compile Include="Support\DefaultScenarioDescriptor.cs" /> | ||
<Compile Include="Support\EndpointBehaviorBuilder.cs" /> | ||
<Compile Include="Support\EndpointConfiguration.cs" /> | ||
<Compile Include="Support\EndpointRunner.cs" /> | ||
<Compile Include="Support\IEndpointSetupTemplate.cs" /> | ||
<Compile Include="Support\IScenarioWithEndpointBehavior.cs" /> | ||
<Compile Include="Support\RunDescriptor.cs" /> | ||
<Compile Include="Support\RunDescriptorsBuilder.cs" /> | ||
<Compile Include="Scenario.cs" /> | ||
<Compile Include="EndpointConfigurationBuilder.cs" /> | ||
<Compile Include="Support\ScenarioConfigSource.cs" /> | ||
<Compile Include="Support\ScenarioDescriptor.cs" /> | ||
<Compile Include="Support\ScenarioException.cs" /> | ||
<Compile Include="Support\ScenarioRunner.cs" /> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | ||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. | ||
Other similar extension points exist, see Microsoft.Common.targets. | ||
<Target Name="BeforeBuild"> | ||
</Target> | ||
<Target Name="AfterBuild"> | ||
</Target> | ||
--> | ||
</Project> |
Oops, something went wrong.