adding the user model for 15.8
This commit is contained in:
parent
5d4fa1ce17
commit
2b95899071
2
cookbook/015/hodgepodge/app/models/user.rb
Normal file
2
cookbook/015/hodgepodge/app/models/user.rb
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
class User < ActiveRecord::Base
|
||||||
|
end
|
@ -0,0 +1,12 @@
|
|||||||
|
class CreateUsers < ActiveRecord::Migration
|
||||||
|
def self.up
|
||||||
|
create_table :users do |t|
|
||||||
|
|
||||||
|
t.timestamps
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.down
|
||||||
|
drop_table :users
|
||||||
|
end
|
||||||
|
end
|
11
cookbook/015/hodgepodge/test/fixtures/users.yml
vendored
Normal file
11
cookbook/015/hodgepodge/test/fixtures/users.yml
vendored
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html
|
||||||
|
|
||||||
|
# This model initially had no columns defined. If you add columns to the
|
||||||
|
# model remove the '{}' from the fixture names and add the columns immediately
|
||||||
|
# below each fixture, per the syntax in the comments below
|
||||||
|
#
|
||||||
|
one: {}
|
||||||
|
# column: value
|
||||||
|
#
|
||||||
|
two: {}
|
||||||
|
# column: value
|
8
cookbook/015/hodgepodge/test/unit/user_test.rb
Normal file
8
cookbook/015/hodgepodge/test/unit/user_test.rb
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
require 'test_helper'
|
||||||
|
|
||||||
|
class UserTest < ActiveSupport::TestCase
|
||||||
|
# Replace this with your real tests.
|
||||||
|
test "the truth" do
|
||||||
|
assert true
|
||||||
|
end
|
||||||
|
end
|
Loading…
Reference in New Issue
Block a user