Permalink
Browse files

Fix formatting of typeof operator and class initialization line break.

  • Loading branch information...
1 parent 53f6b87 commit 58fa087700fb8fdbcd41fd1a5b8f5bbd6ba45d97 @drakomeep drakomeep committed with jeffhandley Oct 21, 2012
Showing with 720 additions and 720 deletions.
  1. +1 −1 Facts/Commands/AutomaticallyCuratePackageCommandFacts.cs
  2. +2 −2 Facts/Commands/CreatedCuratedPackageCommandFacts.cs
  3. +1 −1 Facts/Commands/DeleteCuratedPackageCommandFacts.cs
  4. +1 −1 Facts/Commands/ModifyCuratedPackageCommandFacts.cs
  5. +22 −22 Facts/Controllers/ApiControllerFacts.cs
  6. +2 −2 Facts/Controllers/CuratedFeedsControllerFacts.cs
  7. +28 −28 Facts/Controllers/CuratedPackagesControllerFacts.cs
  8. +49 −49 Facts/Controllers/PackagesControllerFacts.cs
  9. +44 −44 Facts/Controllers/UsersControllerFacts.cs
  10. +9 −9 Facts/PackageCurators/WebMatrixPackageCuratorFacts.cs
  11. +9 −9 Facts/PackageCurators/Windows8PackageCuratorFacts.cs
  12. +4 −4 Facts/Services/CloudBlobFileStorageServiceFacts.cs
  13. +16 −16 Facts/Services/MessageServiceFacts.cs
  14. +5 −5 Facts/Services/NuGetExeDownloaderServiceFacts.cs
  15. +101 −101 Facts/Services/PackageServiceFacts.cs
  16. +60 −60 Facts/Services/UsersServiceFacts.cs
  17. +17 −17 Facts/ViewModels/DisplayPackageViewModelFacts.cs
  18. +14 −14 Website/App_Start/AppActivator.cs
  19. +2 −2 Website/App_Start/AuthenticationModule.cs
  20. +1 −1 Website/App_Start/Configuration.cs
  21. +10 −10 Website/App_Start/ContainerBindings.cs
  22. +5 −5 Website/App_Start/Routes.cs
  23. +6 −6 Website/Commands/CreateCuratedPackageCommand.cs
  24. +5 −5 Website/Controllers/JsonApiController.cs
  25. +18 −18 Website/Controllers/PackagesController.cs
  26. +23 −23 Website/Controllers/UsersController.cs
  27. +1 −1 Website/DataServices/CountInterceptor.cs
  28. +1 −1 Website/DataServices/DisregardODataInterceptor.cs
  29. +11 −11 Website/DataServices/FeedServiceBase.cs
  30. +1 −1 Website/DataServices/ODataRemoveVersionSorter.cs
  31. +62 −62 Website/DataServices/PackageExtensions.cs
  32. +6 −6 Website/DataServices/V1Feed.svc.cs
  33. +3 −3 Website/DataServices/V2CuratedFeed.svc.cs
  34. +5 −5 Website/DataServices/V2Feed.svc.cs
  35. +1 −1 Website/DynamicData/FieldTemplates/DateTime_Edit.ascx.cs
  36. +1 −1 Website/DynamicData/Filters/Boolean.ascx.cs
  37. +1 −1 Website/ExtensionMethods.cs
  38. +82 −82 Website/Migrations/201110060711357_Initial.cs
  39. +15 −15 Website/Migrations/201110180052097_GallerySettings.cs
  40. +8 −8 Website/Migrations/201110230649210_PackageOwnerRequests.cs
  41. +14 −14 Website/Migrations/201203180016174_CuratedFeeds.cs
  42. +5 −5 Website/Migrations/201205172325056_FrameworkName.cs
  43. +1 −1 Website/Migrations/201206250141447_ExecuteELMAHSql.cs
  44. +1 −1 Website/Migrations/SqlResourceMigration.cs
  45. +5 −5 Website/Services/AggregateStatsService.cs
  46. +8 −8 Website/Services/Extensions.cs
  47. +26 −26 Website/Services/PackageService.cs
  48. +7 −7 Website/Services/UserService.cs
@@ -21,7 +21,7 @@ public TestableAutomaticallyCuratePackageCommand()
protected override IEnumerable<T> GetServices<T>()
{
- if (typeof (T) == typeof (IAutomaticPackageCurator))
+ if (typeof(T) == typeof(IAutomaticPackageCurator))
{
return StubCurators.Select(stub => (T)stub.Object);
}
@@ -36,12 +36,12 @@ public TestableCreateCuratedPackageCommand()
protected override T GetService<T>()
{
- if (typeof (T) == typeof (ICuratedFeedByKeyQuery))
+ if (typeof(T) == typeof(ICuratedFeedByKeyQuery))
{
return (T)StubCuratedFeedByKeyQry.Object;
}
- if (typeof (T) == typeof (IPackageRegistrationByKeyQuery))
+ if (typeof(T) == typeof(IPackageRegistrationByKeyQuery))
{
return (T)StubPackageRegistrationByKeyQry.Object;
}
@@ -34,7 +34,7 @@ public TestableDeleteCuratedPackageCommand()
protected override T GetService<T>()
{
- if (typeof (T) == typeof (ICuratedFeedByKeyQuery))
+ if (typeof(T) == typeof(ICuratedFeedByKeyQuery))
{
return (T)StubCuratedFeedByKeyQry.Object;
}
@@ -28,7 +28,7 @@ public TestableModifyCuratedPackageCommand()
protected override T GetService<T>()
{
- if (typeof (T) == typeof (ICuratedFeedByKeyQuery))
+ if (typeof(T) == typeof(ICuratedFeedByKeyQuery))
{
return (T)StubCuratedFeedByKeyQry.Object;
}
@@ -87,10 +87,10 @@ public void WillReturnConflictIfAPackageWithTheIdAndSemanticVersionAlreadyExists
var user = new User();
var packageRegistration = new PackageRegistration
- {
- Packages = new List<Package> { new Package { Version = version.ToString() } },
- Owners = new List<User> { user }
- };
+ {
+ Packages = new List<Package> { new Package { Version = version.ToString() } },
+ Owners = new List<User> { user }
+ };
var packageSvc = new Mock<IPackageService>();
packageSvc.Setup(x => x.FindPackageRegistrationById(It.IsAny<string>())).Returns(packageRegistration);
@@ -262,9 +262,9 @@ public void WillFindTheUserThatMatchesTheApiKey()
{
var owner = new User { Key = 1 };
var package = new Package
- {
- PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
- };
+ {
+ PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
+ };
var packageSvc = new Mock<IPackageService>();
packageSvc.Setup(x => x.FindPackageByIdAndVersion(It.IsAny<string>(), It.IsAny<string>(), true)).Returns(package);
var userSvc = new Mock<IUserService>();
@@ -282,9 +282,9 @@ public void WillNotDeleteThePackageIfApiKeyDoesNotBelongToAnOwner()
{
var owner = new User { Key = 1 };
var package = new Package
- {
- PackageRegistration = new PackageRegistration { Owners = new[] { new User() } }
- };
+ {
+ PackageRegistration = new PackageRegistration { Owners = new[] { new User() } }
+ };
var packageSvc = new Mock<IPackageService>();
packageSvc.Setup(x => x.FindPackageByIdAndVersion(It.IsAny<string>(), It.IsAny<string>(), true)).Returns(package);
packageSvc.Setup(svc => svc.MarkPackageUnlisted(It.IsAny<Package>())).Throws(
@@ -306,9 +306,9 @@ public void WillUnlistThePackageIfApiKeyBelongsToAnOwner()
{
var owner = new User { Key = 1 };
var package = new Package
- {
- PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
- };
+ {
+ PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
+ };
var packageSvc = new Mock<IPackageService>();
packageSvc.Setup(x => x.FindPackageByIdAndVersion(It.IsAny<string>(), It.IsAny<string>(), true)).Returns(package);
var userSvc = new Mock<IUserService>();
@@ -492,9 +492,9 @@ public void WillFindTheUserThatMatchesTheApiKey()
{
var owner = new User { Key = 1 };
var package = new Package
- {
- PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
- };
+ {
+ PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
+ };
var packageSvc = new Mock<IPackageService>();
packageSvc.Setup(x => x.FindPackageByIdAndVersion(It.IsAny<string>(), It.IsAny<string>(), true)).Returns(package);
var userSvc = new Mock<IUserService>();
@@ -512,9 +512,9 @@ public void WillNotListThePackageIfApiKeyDoesNotBelongToAnOwner()
{
var owner = new User { Key = 1 };
var package = new Package
- {
- PackageRegistration = new PackageRegistration { Owners = new[] { new User() } }
- };
+ {
+ PackageRegistration = new PackageRegistration { Owners = new[] { new User() } }
+ };
var packageSvc = new Mock<IPackageService>();
packageSvc.Setup(x => x.FindPackageByIdAndVersion(It.IsAny<string>(), It.IsAny<string>(), true)).Returns(package);
packageSvc.Setup(svc => svc.MarkPackageListed(It.IsAny<Package>())).Throws(
@@ -536,9 +536,9 @@ public void WillListThePackageIfApiKeyBelongsToAnOwner()
{
var owner = new User { Key = 1 };
var package = new Package
- {
- PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
- };
+ {
+ PackageRegistration = new PackageRegistration { Owners = new[] { new User(), owner } }
+ };
var packageSvc = new Mock<IPackageService>();
packageSvc.Setup(x => x.FindPackageByIdAndVersion(It.IsAny<string>(), It.IsAny<string>(), true)).Returns(package);
var userSvc = new Mock<IUserService>();
@@ -15,7 +15,7 @@ public class TestableCuratedFeedsController : CuratedFeedsController
public TestableCuratedFeedsController()
{
StubCuratedFeed = new CuratedFeed
- { Key = 0, Name = "aName", Managers = new HashSet<User>(new[] { new User { Username = "aUsername" } }) };
+ { Key = 0, Name = "aName", Managers = new HashSet<User>(new[] { new User { Username = "aUsername" } }) };
StubCuratedFeedByNameQry = new Mock<ICuratedFeedByNameQuery>();
StubIdentity = new Mock<IIdentity>();
@@ -37,7 +37,7 @@ protected override IIdentity Identity
protected override T GetService<T>()
{
- if (typeof (T) == typeof (ICuratedFeedByNameQuery))
+ if (typeof(T) == typeof(ICuratedFeedByNameQuery))
{
return (T)StubCuratedFeedByNameQry.Object;
}
@@ -15,7 +15,7 @@ protected TestableCuratedPackagesControllerBase()
{
StubCreatedCuratedPackageCmd = new Mock<ICreateCuratedPackageCommand>();
StubCuratedFeed = new CuratedFeed
- { Key = 0, Name = "aName", Managers = new HashSet<User>(new[] { new User { Username = "aUsername" } }) };
+ { Key = 0, Name = "aName", Managers = new HashSet<User>(new[] { new User { Username = "aUsername" } }) };
StubCuratedFeedByNameQry = new Mock<ICuratedFeedByNameQuery>();
StubDeleteCuratedPackageCmd = new Mock<IDeleteCuratedPackageCommand>();
StubIdentity = new Mock<IIdentity>();
@@ -43,27 +43,27 @@ protected override IIdentity Identity
protected override T GetService<T>()
{
- if (typeof (T) == typeof (ICreateCuratedPackageCommand))
+ if (typeof(T) == typeof(ICreateCuratedPackageCommand))
{
return (T)StubCreatedCuratedPackageCmd.Object;
}
- if (typeof (T) == typeof (ICuratedFeedByNameQuery))
+ if (typeof(T) == typeof(ICuratedFeedByNameQuery))
{
return (T)StubCuratedFeedByNameQry.Object;
}
- if (typeof (T) == typeof (IDeleteCuratedPackageCommand))
+ if (typeof(T) == typeof(IDeleteCuratedPackageCommand))
{
return (T)StubDeleteCuratedPackageCmd.Object;
}
- if (typeof (T) == typeof (IModifyCuratedPackageCommand))
+ if (typeof(T) == typeof(IModifyCuratedPackageCommand))
{
return (T)StubModifyCuratedPackageCmd.Object;
}
- if (typeof (T) == typeof (IPackageRegistrationByIdQuery))
+ if (typeof(T) == typeof(IPackageRegistrationByIdQuery))
{
return (T)StubPackageRegistrationByIdQry.Object;
}
@@ -114,13 +114,13 @@ public void WillDeleteTheCuratedPackageWhenRequestIsValid()
var controller = new TestableCuratedPackagesController();
controller.StubCuratedFeed.Key = 42;
controller.StubCuratedFeed.Packages = new[]
- {
- new CuratedPackage
- {
- Key = 1066,
- PackageRegistration = new PackageRegistration { Id = "theCuratedPackageId" }
- }
- };
+ {
+ new CuratedPackage
+ {
+ Key = 1066,
+ PackageRegistration = new PackageRegistration { Id = "theCuratedPackageId" }
+ }
+ };
controller.DeleteCuratedPackage("theCuratedFeedName", "theCuratedPackageId");
@@ -147,10 +147,10 @@ public TestableCuratedPackagesController()
{
StubCuratedFeed.Managers = new[] { new User { Username = "aUsername" } };
StubCuratedFeed.Packages = new[]
- {
- new CuratedPackage
- { PackageRegistration = new PackageRegistration { Id = "aCuratedPackageId" } }
- };
+ {
+ new CuratedPackage
+ { PackageRegistration = new PackageRegistration { Id = "aCuratedPackageId" } }
+ };
StubCuratedFeedByNameQry
.Setup(stub => stub.Execute(It.IsAny<string>(), It.IsAny<bool>()))
.Returns(StubCuratedFeed);
@@ -262,13 +262,13 @@ public void WillModifyTheCuratedPackageWhenRequestIsValid()
var controller = new TestableCuratedPackagesController();
controller.StubCuratedFeed.Key = 42;
controller.StubCuratedFeed.Packages = new[]
- {
- new CuratedPackage
- {
- Key = 1066,
- PackageRegistration = new PackageRegistration { Id = "theCuratedPackageId" }
- }
- };
+ {
+ new CuratedPackage
+ {
+ Key = 1066,
+ PackageRegistration = new PackageRegistration { Id = "theCuratedPackageId" }
+ }
+ };
controller.PatchCuratedPackage("theCuratedFeedName", "theCuratedPackageId", new ModifyCuratedPackageRequest { Included = true });
@@ -297,10 +297,10 @@ public TestableCuratedPackagesController()
{
StubCuratedFeed.Managers = new[] { new User { Username = "aUsername" } };
StubCuratedFeed.Packages = new[]
- {
- new CuratedPackage
- { PackageRegistration = new PackageRegistration { Id = "aCuratedPackageId" } }
- };
+ {
+ new CuratedPackage
+ { PackageRegistration = new PackageRegistration { Id = "aCuratedPackageId" } }
+ };
StubCuratedFeedByNameQry
.Setup(stub => stub.Execute(It.IsAny<string>(), It.IsAny<bool>()))
.Returns(StubCuratedFeed);
Oops, something went wrong.

0 comments on commit 58fa087

Please sign in to comment.