Sha256: 64ace88bd8fa5d6ca1273cd995a6d726616b09b3da6f4a5c206873fa5017d6fa

Contents?: true

Size: 587 Bytes

Versions: 92

Compression:

Stored size: 587 Bytes

Contents

require "spec_helper"

describe Dynomite::Migration::Generator do
  before(:each) do
    FileUtils.rm_rf("#{Dynomite.app_root}dynamodb/migrate")
  end

  let(:generator) do
    Dynomite::Migration::Generator.new("comments",
      partition_key: "post_id:string",
      sort_key: "created_at:string",
      quiet: true
    )
  end

  it "generates migration file in dynamodb/migrate" do
    generator.generate

    migration_path = Dir.glob("#{Dynomite.app_root}dynamodb/migrate/*").first
    migration_exist = File.exist?(migration_path)
    expect(migration_exist).to be true
  end
end

Version data entries

92 entries across 92 versions & 1 rubygems

Version Path
jets-1.4.10 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.9 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.8 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.7 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.6 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.5 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.4 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.3 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.2 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.1 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.4.0 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.9 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.8 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.7 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.6 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.5 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.4 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.3 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.2 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb
jets-1.3.1 vendor/dynomite/spec/lib/dynomite/migration/generator_spec.rb