Sha256: 6a6ec84c17ca0c521ea0286bca342b34c81f58faaa714cf6c15aee7e156f65ad
Contents?: true
Size: 653 Bytes
Versions: 3
Compression:
Stored size: 653 Bytes
Contents
require 'test_helper' module PushType class UserTest < ActiveSupport::TestCase let(:user) { User.new } it { user.wont_be :valid? } it 'should be valid with required attributes' do user.attributes = FactoryBot.attributes_for :user user.must_be :valid? end describe '#initials' do let(:user_one) { User.new name: 'Joe' } let(:user_two) { User.new name: 'Joe Bloggs' } let(:user_three) { User.new name: 'Joe Smithe Henley-Bloggs' } it { user_one.initials.must_equal 'J' } it { user_two.initials.must_equal 'JB' } it { user_three.initials.must_equal 'JH' } end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
push_type_core-0.12.1 | test/models/push_type/user_test.rb |
push_type_core-0.12.0 | test/models/push_type/user_test.rb |
push_type_core-0.12.0.beta.1 | test/models/push_type/user_test.rb |