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
// Global reset rules. | |
// For more specific resets, use the reset mixins provided below | |
=global-reset | |
html, body, div, span, applet, object, iframe, | |
h1, h2, h3, h4, h5, h6, p, blockquote, pre, | |
a, abbr, acronym, address, big, cite, code, | |
del, dfn, em, font, img, ins, kbd, q, s, samp, | |
small, strike, strong, sub, sup, tt, var, | |
dl, dt, dd, ol, ul, li, | |
fieldset, form, label, legend, |
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
# Download all images from a stock exchange lightbox | |
require 'rubygems' | |
require 'mechanize' | |
require 'logger' | |
agent = Mechanize.new { |a| a.log = Logger.new("mech.log") } | |
agent.user_agent_alias = 'Mac Safari' | |
page = agent.get("http://www.sxc.hu/") |
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
@items = MyModel.all | |
@columns = MyModel.column_names | |
respond_to do |format| | |
format.csv do | |
my_csv = FasterCSV.generate do |csv| | |
# header row | |
csv << @columns | |
# data rows |
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
*** LOCAL GEMS *** | |
abstract (1.0.0) | |
actionmailer (3.1.0.rc1, 3.0.7, 3.0.7.rc2) | |
actionpack (3.1.0.rc1, 3.0.7, 3.0.7.rc2) | |
activemodel (3.1.0.rc1, 3.0.7, 3.0.7.rc2) | |
activerecord (3.1.0.rc1, 3.0.7, 3.0.7.rc2) | |
activeresource (3.1.0.rc1, 3.0.7, 3.0.7.rc2) | |
activesupport (3.1.0.rc1, 3.0.7, 3.0.7.rc2) | |
ansi (1.2.5) |
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
$('#user_button').toggle(function () { | |
$("#user_button").css({borderBottomLeftRadius: "0px"}); | |
}, function () { | |
$("#user_button").css({borderBottomLeftRadius: "5px"}); | |
}); |
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
require 'factory_girl' | |
Factory.define :role do |r| | |
r.name 'SuperAdmin' | |
end | |
Factory.define :user do |u| | |
u.username "gomezn" | |
u.association :roles, :factory => :role | |
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
require 'spec_helper' | |
describe User do | |
let(:user) do | |
Factory(:user, :username=>"gomezn") | |
end | |
let(:role) do | |
Factory(:role) |
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
Failures: | |
1) User should not allow for multiple users with the same username | |
Failure/Error: Factory(:user, :username=>"gomezn") | |
ActiveRecord::RecordInvalid: | |
Validation failed: Name has already been taken | |
# ./spec/models/user_spec.rb:6 | |
# ./spec/models/user_spec.rb:35 | |
2) User should have ldap |
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
<table id="roles"> | |
<thead> | |
<tr> | |
<% @columns.each do |column| %> | |
<th class="center"><%= column %></th> | |
<% end %> | |
</tr> | |
</thead> | |
<tbody> | |
<% @Roles.each_with_index do |role, index| %> |
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
NOTE: Gem.source_index is deprecated, use Specification. It will be removed on or after 2011-11-01. | |
Gem.source_index called from /Users/noel/apps/kete/config/../vendor/rails/railties/lib/rails/gem_dependency.rb:21. | |
NOTE: Gem::SourceIndex#refresh! is deprecated with no replacement. It will be removed on or after 2011-11-01. | |
Gem::SourceIndex#refresh! called from /Users/noel/apps/kete/config/../vendor/rails/railties/lib/rails/vendor_gem_source_index.rb:34. | |
NOTE: Gem::SourceIndex#load_gems_in is deprecated with no replacement. It will be removed on or after 2011-11-01. | |
Gem::SourceIndex#load_gems_in called from /Users/noel/.rvm/rubies/ruby-1.8.7-p357/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:322. | |
NOTE: Gem::SourceIndex#add_spec is deprecated, use Specification.add_spec. It will be removed on or after 2011-11-01. | |
Gem::SourceIndex#add_spec called from /Users/noel/.rvm/rubies/ruby-1.8.7-p357/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:127. | |
NOTE: Gem::SourceIndex#add_spec is deprecated, use Specification.add |
OlderNewer