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
[TestFixture] | |
public class RouteTestFixture | |
{ | |
[Test] | |
public void Routes_should_not_change() | |
{ | |
const string good = @"admin/event/lasteventhandlererror/;admin/event/search/AdminEventSearch;admin/event/{id}/AdminEventGet;admin/event/{seq}/byseq/AdminEventGetBySeq;admin/event/max/GetMaxEvent;admin/event/previous/GetEventBefore;admin/event/seq/GetSeq;admin/event/publish/test/;admin/event/skip/{seq=}/;admin/event/skipend/;admin/event/maxseq/;address/addressSearch;address/warnings/{state}/{suburb}/addressWarnings;calendar/{calendarName}/allCalendars;jobAddress/search/;booking/{bookingId}/documents/AddBookingDocuments;booking/{bookingId}/document/{documentId}/TagBookingDocument;booking/{bookingId}/document/{documentId}/DeleteBookingDocument;getStructerreValidGuid/GetStructerreValidGuid;booking/{id}/GetBooking;bookings/NewBooking;booking/{id}/UpdateBooking;booking/{id}/DeleteBookingDraft;booking/{id}/submit/SubmitBooking;bookingproject/{projectId}/bookingProjectDetails;b |
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
$Until = New-TimeSpan -End "2036-01-01" | |
$User = "SYSTEM" | |
$Path = Resolve-Path MyCustom.Tasks.exe | |
Function ScheduleTask($name, $task, $time) | |
{ | |
$Trigger = New-ScheduledTaskTrigger -Once -At $time -RepetitionInterval (New-TimeSpan -Days 1) -RepetitionDuration $Until |
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
module ChrisMcKelt | |
open System | |
open System.ServiceModel | |
open Microsoft.FSharp.Linq | |
open Microsoft.FSharp.Data.TypeProviders | |
open System.Linq | |
let rec chop (arr:array<int>, low:int, high:int, value:int) = | |
if (high < low) then | |
null |
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
/* tslint:disable */ | |
var files = { | |
jquery: "./app/scripts/jquery-1.10.2.js", | |
angular: "./app/scripts/angular.js", | |
angularAnimate: "./app/scripts/angular-animate.js", | |
angularSanitize: "./app/scripts/angular/angular-sanitize", | |
angularUIRouter: "./app/scripts/angular-ui/angular-ui-router", | |
angularMocks: "./app/scripts/angular/angular-mocks", | |
underscore: "./app/scripts/underscore", |
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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Reflection; | |
using Castle.Windsor; | |
using Iesi.Collections; | |
using Newtonsoft.Json; | |
using Structerre.MetaStore.Framework.Events; | |
using Structerre.MetaStore.Framework.Handlers; | |
using Structerre.MetaStore.Framework.Logging; |
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
#Administrator privileges check | |
If (-NOT ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole(` | |
[Security.Principal.WindowsBuiltInRole] "Administrator")) | |
{ | |
Write-Warning "You do not have Administrator rights!`nPlease run the build shell as administrator!" | |
exit | |
} | |
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
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
using System.ComponentModel; | |
using System.Diagnostics; | |
using System.Dynamic; | |
using System.Linq.Expressions; | |
using System.Reflection; | |
using System.Text; | |
using NSubstitute; |
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
[Fact] | |
public void PopulatesFranchiseSummary() | |
{ | |
When(_ => _handler.Handle(_createdEvent)); | |
Then(session => | |
{ | |
var loanContract = session.Get<PersonalLoanContract>(_createdEvent.AggregateId); | |
//original - manual anon |
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
public static dynamic ToDynamic(this object value) | |
{ | |
IDictionary<string, object> expando = new ExpandoObject(); | |
foreach (PropertyDescriptor property in TypeDescriptor.GetProperties(value.GetType())) | |
expando.Add(property.Name, property.GetValue(value)); | |
return expando as ExpandoObject; | |
} |
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
namespace CodeDojo | |
module CodeDojo_Anagram = | |
open System | |
open System.ServiceModel | |
open System.Collections.Generic | |
open Microsoft.FSharp.Linq | |
open FSharp.Control |
OlderNewer