Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Brandon Satrom bsatrom

🏠
Working from home
View GitHub Profile
View Cuke4NukeSourceTagNamesIssue.bat
D:\Development\Cuke4Nuke\examples\Calc\CalcFeatures>Cuke4Nuke D:\Development\Cuke4Nuke\examples\Calc\Calc\bin\Debug\Calc.dll -c | F:\Downloads\Wac.exe
# language: en
Feature: Addition
In order to avoid silly mistakes
As a math idiot
I want to be told the sum of two numbers
Scenario Outline: Add two numbers # features\addition.feature:7
Given I have entered <input_1> into the calculator # features\addition.feature:8
And I have entered <input_2> into the calculator # features\addition.feature:9
View Cuke4NukeLog.txt
2010-03-05 11:12:16,322 [1] INFO Cuke4Nuke.Server.NukeServer - Listening on port 3901
2010-03-05 11:12:16,323 [1] INFO Cuke4Nuke.Server.NukeServer - Waiting for client to connect.
2010-03-05 11:12:17,523 [1] INFO Cuke4Nuke.Server.NukeServer - Connected to client.
2010-03-05 11:12:17,526 [1] INFO Cuke4Nuke.Server.NukeServer - Waiting for request.
2010-03-05 11:12:17,526 [1] INFO Cuke4Nuke.Server.NukeServer - Received request <["step_matches",{"name_to_match":"I have entered 20 into the calculator"}]>.
2010-03-05 11:12:17,616 [1] INFO Cuke4Nuke.Server.NukeServer - Responded with <["step_matches",[]]>.
2010-03-05 11:12:17,616 [1] INFO Cuke4Nuke.Server.NukeServer - Waiting for request.
2010-03-05 11:12:17,617 [1] INFO Cuke4Nuke.Server.NukeServer - Received request <["step_matches",{"name_to_match":"I have entered 2 into the calculator"}]>.
2010-03-05 11:12:17,617 [1] INFO Cuke4Nuke.Server.NukeServer - Responded with <["step_matches",[]]>.
2010-03-05 11:12:17,617 [1] INFO Cuke4Nuke.Server.NukeServer - Wa
View ExampleUsage.cs
int userId = StackOverflowApiHelper.GetUserId("satrom");
Assert.AreEqual(380135, userId);
@bsatrom
bsatrom / ie9ify.tests.js
Created Mar 25, 2011
Using qunit and jsmock to test the ie9ify plugin. Sadly, it doesn't look like I can mock any of the new site mode functions
View ie9ify.tests.js
// Getting closer...
var ctrl = new MockControl();
var windowMock = ctrl.createMock(window.external);
//normally, you wouldn't need this next line, but it seems to be required in this case because window.external is a black box
windowMock.addMockMethod('msIsSiteMode');
windowMock.expects().msIsSiteMode().andReturn(true);
//But this is still false...
View ie9ify.init.js
$('head').ie9ify({
applicationName: 'mySite',
favIcon: 'favicon.ico',
navColor: 'Green',
startUrl: '/Home',
tooltip: 'mySite,
window: 'width=800;height=600',
tasks: [{
'name': 'Twitter',
'action': 'http://twitter.com/brandonsatrom',
View thumbbars.js
$.ie9ify.createThumbbarButtons({
buttons: [{
icon: 'images/play.ico',
name: 'Play Slideshow',
alternateStyle: {
icon: 'images/pause.ico',
name: 'Pause Slideshow'
},
click: function () {
var slideshow = $('#slideshow');
View thumbbars.js
$.ie9ify.createThumbbarButtons({
buttons: [{
icon: 'images/play.ico',
name: 'Play Slideshow',
alternateStyle: {
icon: 'images/pause.ico',
name: 'Pause Slideshow'
},
click: function () {
var slideshow = $('#slideshow');
View topHat.js
$('#topHatContainer').ie9ify('pinTeaser', {
type: 'topHat',
pinText: 'Unlock the hidden powers of this site with a click and a drag.',
style: {
backgroundImage: 'images/toolbar-bg.png',
closeButtonImage: 'images/toolbar-bg.png'
}
});
View brandedTopHat.js
$('#brandedTopHatContainer').ie9ify('pinTeaser', {
type: 'brandedTopHat',
pinText: 'Unlock the hidden powers of this site with a click and a drag.',
secondaryText: 'Drag the icon to your taskbar.',
style: {
backgroundImage: 'images/branding_bar_custom_bg.png',
closeButtonImage: 'images/toolbar-bg.png'
}
});
View doubleTopHat
$('#doubleTopHatContainer').ie9ify('pinTeaser', {
type: 'doubleTopHat',
pinText: 'Unlock the hidden powers of this site with a click and a drag.',
style: {
rightBackgroundImage: 'images/left_image.png',
leftBackgroundImage: 'images/right_image.png'
}
});