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
@Test | |
public void shouldLoadAllBeansFromSpringContext() throws Exception { | |
for(String bean : new String[]{"productInputFormat", "upgradingMapper", "upgradeJob"}) | |
Assert.assertNotNull(context.getBean(bean)); | |
} |
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
$: << File.dirname(__FILE__) | |
require 'spec_helper' | |
describe "Product REST Service findByUpdateDate" do | |
before(:each) do | |
end | |
it 'should only find products created within the date ran ge given' do |
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 BookInfoJaxBImpl(BookInfo bookInfo) { | |
if(bookInfo==null) | |
throw new IllegalArgumentException("BookInfo passed into the constructor cannot be null."); | |
else | |
load(bookInfo); | |
} | |
private void load(BookInfo bookInfo) { | |
//load the values of BookInfo into this instance | |
} |
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
javascript:(function(){var k=" -site:experts-exchange.com -site:swik.net";if(document.f){document.f.q.value=document.f.q.value+k;}else{document.gs.q.value=document.gs.q.value+k}})() |
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
javascript:( | |
function(){ | |
var k=" -site:expertsexchange.com -site:swik.net"; | |
if(document.f){ | |
document.f.q.value=document.f.q.value+k; | |
}else{ | |
document.gs.q.value=document.gs.q.value+k | |
}})() |
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 String[] getJobNames() { | |
return Transform.map(new Unary<JobConf, String>(){ | |
public String f(JobConf item) { | |
return item.getJobName(); | |
} | |
}, context.getBeansOfType(JobConf.class).values()).toArray(new String[]{}); | |
} |
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
def get_job_names | |
context.getBeansOfType(JobConf).collect do |beanGetJobName,bean| | |
bean.getJobName | |
end | |
end |
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
CmdUtils.CreateCommand({ | |
name: "subscribe", | |
description: "Subscribe to a feed for the current page in Google Reader -- I didn't write this. I found it on the web somewhere (that I've now forgotten) and just pasted it here to test Gists Ubiquity command functionality.", | |
help: "Subscribe to a feed for the current page in Google Reader (does same thing as their bookmarklet)", | |
execute: function(tags) { | |
var document = context.focusedWindow.document; | |
var b=document.body; | |
var GR________bookmarklet_domain='http://www.google.com'; | |
if (b&&!document.xmlVersion) { | |
void(z=document.createElement('script')); |
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
// HiveDB uses a partition by key strategy so you must select a relevant | |
// property of the data to use to split the data set. We call this the | |
// partitioning key. Ideally, this should be a dimension or relationship | |
// that you never need to join across since HiveDB does not support joins | |
// across shards. | |
// | |
// Insert the partitioning key in order to allocate it to a shard. | |
// [In this example we are partitioning silverware by type.] | |
hive.directory().insertPrimaryIndexKey(spork.getType()); | |
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
config.gem "rspec", :version => ">= 1.2.6", :lib => 'spec' | |
config.gem "rspec-rails", :version => ">= 1.2.6", :lib => 'spec/rails' |
OlderNewer