Skip to content

Instantly share code, notes, and snippets.

View adamstrickland's full-sized avatar

Adam Strickland adamstrickland

  • New York, NY
View GitHub Profile
<ioc-config>
<service name="com.thinkfinance.es.data-acquisition.IDataAcquisitionService" class="com.thinkfinance.es.data-acquisition.LeadGenDataAcquisitionService">
<constructor-args>
<arg>
<list>
<object class="com.thinkfinance.es.data-acquisition.providers.ClarityProvider"/>
</list>
</arg>
<arg>
<list>
@adamstrickland
adamstrickland / gist:2998167
Created June 26, 2012 19:16
sample "correlation service" configuration
<configuration>
<definitions>
<predicate-definition name="still-needs-demographics">
<![CDATA[
function (context, data) {
return context.requiresAdditionalInformation() && context.openInquiries().count === 0 && !data.hasDemographics();
}
]]>
</predicate-definition>
</definitions>
Scenario: landing page
When I am on the landing page
Then I should see "My E-Commerce Landing Page"
Scenario: no account
Given I do not have an account
When I go to the terms and conditions page
Then I should be redirected to the create account page
Scenario: not logged in
@adamstrickland
adamstrickland / gist:1227691
Created September 19, 2011 21:41
possible rule engine impl
/*interface IGrade
{
decimal Min{ get; set; }
decimal Max{ get; set; }
}
Grade grade0 = new Grade{ Min = 0, Max = 10000 };
Grade grade1 = new Grade{ Min = 10000, Max = 50000 };
Grade grade2 = new Grade{ Min = 50000, 100000 };
use enterprise
go
with events (exceptionInfo, eventMessageDate) as (
select top 10000
M.exceptionInfo, M.eventMessageDate
from serviceEvent E
inner join serviceEventMessage M on E.eventId = M.eventId
where username = 'john.mcgilberry'
--where eventMessageDate >= '8/15/2011'
Scenario: Get List of My Hitchhiking Items via API
Given the existing things:
|name|
|The Guide (duh)|
|A towel|
|Sub-Etha Sens-O-Matic|
|Pan Galactic Gargle Blaster|
|Kill-o-Zap blaster pistol|
And the existing accounts:
|email|name|password|
def bind_alt_socket(alt_ip):
true_socket = socket.socket
def bound_socket(*a, **k):
sock = true_socket(*a, **k)
sock.bind((alt_ip, 0))
return sock
socket.socket = bound_socket