Skip to content

Instantly share code, notes, and snippets.

View ohcibi's full-sized avatar
🕴️
Elevated

Tobias Witt ohcibi

🕴️
Elevated
View GitHub Profile
class PageWidget < ActiveRecord::Base
attr_accessible :width, :height, :offset_x, :offset_y, :widget_id
validates :page_id, presence: true
validates :widget_id, presence: true
belongs_to :page
belongs_to :widget
end
class Page < ActiveRecord::Base
attr_accessible :title
has_many :page_widgets
has_many :widgets, through: :page_widgets
[ 266.522]
X.Org X Server 1.11.2
Release Date: 2011-11-04
[ 266.522] X Protocol Version 11, Revision 0
[ 266.523] Build Operating System: Linux 3.0.6-gentoo x86_64 Gentoo
[ 266.523] Current Operating System: Linux amsterdam 3.2.12-gentoo #2 SMP Mon May 14 17:09:55 CEST 2012 x86_64
[ 266.523] Kernel command line: root=/dev/sda5
[ 266.524] Build Date: 21 December 2011 07:51:14PM
[ 266.524]
[ 266.524] Current version of pixman: 0.24.0
RubyGems Environment:
- RUBYGEMS VERSION: 1.8.24
- RUBY VERSION: 1.9.3 (2012-04-20 patchlevel 194) [x86_64-linux]
- INSTALLATION DIRECTORY: /home/ohcibi/.rvm/gems/ruby-1.9.3-p194
- RUBY EXECUTABLE: /home/ohcibi/.rvm/rubies/ruby-1.9.3-p194/bin/ruby
- EXECUTABLE DIRECTORY: /home/ohcibi/.rvm/gems/ruby-1.9.3-p194/bin
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-linux
- GEM PATHS:
if [[ "$DISPLAY" = "" && "`tty`" = "/dev/tty1" ]]; then
eval `keychain -q --eval id_rsa`
startx &
fi
[16] pry(main)> [{"a" => 1}] == [{:a => 1}]
=> false
69: end
70: pages[2].reload
71: end
72: its(:menu_order) { should == 1}
73: it "should add an excluded css class to the pages control" do
=> 74: binding.pry
75: visit admin_pages_path
76: page.should_not have_selector "li.excluded#page_#{pages[2].id}"
77: end
69: end
70: pages[2].reload
71: end
72: its(:menu_order) { should == 1}
73: it "should add an excluded css class to the pages control" do
=> 74: binding.pry
75: visit admin_pages_path
76: page.should_not have_selector "li.excluded#page_#{pages[2].id}"
77: end
match '/:page', to: "pages#show"
<?php
class GlassTest extends CakeTestCase {
public function setUp() {
parent::setUp();
$this->Glass = ClassRegistry::init('Glass');
}
public function tearDown() {
parent::tearDown();
$this->Glass->query('TRUNCATE ' . $this->Glass->tablePrefix . $this->Glass->table);
}