Sha256: 2469d015efb2f31875e442fec058c24da39c3e3dfb7992b84ba9574a85cd4fcb

Contents?: true

Size: 464 Bytes

Versions: 5

Compression:

Stored size: 464 Bytes

Contents

require_relative 'test_helper'

class BlobModelTest < ActiveSupport::TestCase
  setup do
    blob_data = 'Hello blob world!'
    @blob = GemTestBlob.new data: blob_data,
                            id: GemTestBlob.id_for('blob_data')
  end

  test 'setup' do
    assert @blob.valid?, @blob.errors
  end

  test 'requires an id' do
    @blob.id = nil
    assert !@blob.valid?
  end

  test 'requires data' do
    @blob.data = nil
    assert !@blob.valid?
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
file_blobs_rails-0.2.3 test/blob_model_test.rb
file_blobs_rails-0.2.2 test/blob_model_test.rb
file_blobs_rails-0.2.1 test/blob_model_test.rb
file_blobs_rails-0.2.0 test/blob_model_test.rb
file_blobs_rails-0.1.0 test/blob_model_test.rb