Sha256: f7d544803398080c03c595805a53a0d8c74b99175f9d4076a076d59abc4d8948

Contents?: true

Size: 860 Bytes

Versions: 11

Compression:

Stored size: 860 Bytes

Contents

require 'rails_helper'
  
describe UserExportFile do
  fixtures :all
  
  it "should export users" do
    message_count = Message.count
    file = UserExportFile.create(user: users(:admin))
    file.export!
    #UserExportFileJob.perform_later(file).should be_truthy
    Message.count.should eq message_count + 1
    Message.order(:created_at).last.subject.should eq "エクスポートが完了しました: #{file.id}"
  end
end

# == Schema Information
#
# Table name: user_export_files
#
#  id                       :integer          not null, primary key
#  user_id                  :integer
#  user_export_file_name    :string
#  user_export_content_type :string
#  user_export_file_size    :integer
#  user_export_updated_at   :datetime
#  executed_at              :datetime
#  created_at               :datetime
#  updated_at               :datetime
#

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
enju_library-0.3.11 spec/models/user_export_file_spec.rb
enju_library-0.3.10 spec/models/user_export_file_spec.rb
enju_library-0.3.9 spec/models/user_export_file_spec.rb
enju_library-0.3.8 spec/models/user_export_file_spec.rb
enju_library-0.3.8.rc.2 spec/models/user_export_file_spec.rb
enju_library-0.3.8.rc.1 spec/models/user_export_file_spec.rb
enju_library-0.3.7 spec/models/user_export_file_spec.rb
enju_library-0.3.6 spec/models/user_export_file_spec.rb
enju_library-0.3.5 spec/models/user_export_file_spec.rb
enju_library-0.3.4 spec/models/user_export_file_spec.rb
enju_library-0.3.3 spec/models/user_export_file_spec.rb