Displaying 2 results from an estimated 2 matches for "mediajoint".
2007 Aug 06
2
Specifying custom rails FormBuilders
I want to write a spec for a custom form builder, but I''m not really
sure where it should live or how to include the right rspec_on_rails
contexts. Ideally, I should be able to write a spec like:
describe LabelledBuilder do
it "should let me create a text field" do
object = mock(object)
object.stub!(:attribute).and_return("Test String")
render
2007 Aug 27
7
Foreign key constraints, fixtures, and rake task
...This works
fine running scripts/spec, but when I run rake spec instead, I get:
ActiveRecord::StatementInvalid in ''User in fixture :quentin with an IM
service but no IM name should be invalid''
Mysql::Error: Cannot delete or update a parent row: a foreign key
constraint fails (`mediajoint_development/accounts`, CONSTRAINT
`accounts_opener_id_fk` FOREIGN KEY (`opener_id`) REFERENCES `users`
(`id`)): DELETE FROM users
/Users/jay/Documents/eclipse/mediajoint/vendor/plugins/rspec_on_rails/lib/spec/rails/dsl/behaviour/model.rb:12:in
`before_eval''
I''ve even manually...