Skip to content

Instantly share code, notes, and snippets.

[Test]
public virtual void ShouldAllReturnHello()
{
AssertAll
(
() => Assert.AreEqual("Hello", "World"),
() => Assert.AreEqual("Hello", "Kevin"),
() => Assert.AreEqual("Hello", "Jimmy"),
() => Assert.AreEqual("Hello", "Hello")
);
agrreagrgegerg
dfwffwer
@jbosse
jbosse / UnitTestsPresenter.cs
Created November 29, 2010 16:45
UnitTestsPresenter
using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
namespace Website.App_Code.UnitTests
{
public class TestResult
{
public string Test { get; set; }
@jbosse
jbosse / ControlExtensions.cs
Created December 16, 2010 19:28
ControlExtensions.cs
public static class ControlExtensions
{
public static T Find<T>(this Control control, string id) where T : Control
{
return (T) control.FindControl(id);
}
}
@jbosse
jbosse / ninjecthack.cs
Created April 12, 2012 00:11
Hack around Ninject 2 => 3 api change
using System.Linq;
using Hudoo.Web.App_Start;
namespace Hudoo.Web.Test.DeleporterHelpers
{
public static class NinjectControllerFactoryUtils
{
public static void TemporarilyReplaceBinding<TService>(TService implementation)
{
// get a handle on the Ninject Kernel (how you do this will depend on how you setup the Kernel)
@jbosse
jbosse / blank.sln
Created January 11, 2013 18:11
blank solution
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
Global
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal
@jbosse
jbosse / ,loader
Created February 28, 2013 16:46
dynamic load js
<script>
(function (undefined) {
try {
if (jQuery !== undefined) {
return;
}
} catch (e) {
var body = document.getElementsByTagName('body')[0];
var jqueryScript = document.createElement("script");
Delivered-To: jimmy@thebosses.net
Received: by 10.64.21.170 with SMTP id w10csp162906iee;
Mon, 4 Nov 2013 11:22:59 -0800 (PST)
X-Received: by 10.224.131.67 with SMTP id w3mr24722838qas.62.1383592978812;
Mon, 04 Nov 2013 11:22:58 -0800 (PST)
Return-Path: <sn6456@aol.com>
Received: from eastrmfepo201.cox.net (eastrmfepo201.cox.net. [68.230.241.216])
by mx.google.com with ESMTP id p5si4246755qcp.52.2013.11.04.11.22.58
for <jimmy@thebosses.net>;
Mon, 04 Nov 2013 11:22:58 -0800 (PST)
@jbosse
jbosse / xcode-build-bump.sh
Created October 24, 2015 17:59 — forked from sekati/xcode-build-bump.sh
Xcode Auto-increment Build & Version Numbers
# xcode-build-bump.sh
# @desc Auto-increment the build number every time the project is run.
# @usage
# 1. Select: your Target in Xcode
# 2. Select: Build Phases Tab
# 3. Select: Add Build Phase -> Add Run Script
# 4. Paste code below in to new "Run Script" section
# 5. Drag the "Run Script" below "Link Binaries With Libraries"
# 6. Insure that your starting build number is set to a whole integer and not a float (e.g. 1, not 1.0)