spec/readme_spec.rb in with_model-1.2.0 vs spec/readme_spec.rb in with_model-1.2.1

- old
+ new

@@ -11,11 +11,11 @@ with_model :BlogPost do # The table block works just like a migration. table do |t| t.string :title - t.timestamps + t.timestamps null: false end # The model block works just like the class definition. model do include SomeModule @@ -35,11 +35,11 @@ # with_model classes can have associations. with_model :Comment do table do |t| t.string :text t.belongs_to :blog_post - t.timestamps + t.timestamps null: false end model do belongs_to :blog_post end @@ -109,10 +109,10 @@ describe "with table options" do with_model :WithOptions do table :id => false do |t| t.string 'foo' - t.timestamps + t.timestamps null: false end end it "respects the additional options" do expect(WithOptions.columns.map(&:name)).to_not include("id")