mirror of
https://github.com/discourse/discourse.git
synced 2025-02-03 22:50:45 +08:00
fcff4e80d1
This is information that is not usually needed when representing a user and is in a separate table with a has one relationship to avoid querying it all the time.
12 lines
217 B
Ruby
12 lines
217 B
Ruby
require 'spec_helper'
|
|
|
|
describe UserStat do
|
|
|
|
it { should belong_to :user }
|
|
|
|
it "is created automatically when a user is created" do
|
|
user = Fabricate(:evil_trout)
|
|
user.user_stat.should be_present
|
|
end
|
|
|
|
end |