Sha256: 3df51f30bb1290f8ecb626bc2603bec46ff769db91bf25cb64a4706c4e9bdbdf

Contents?: true

Size: 1.87 KB

Versions: 305

Compression:

Stored size: 1.87 KB

Contents

# -*- ruby encoding: utf-8 -*-

require 'spec_helper'

describe Diff::LCS::Change do
  describe "an add" do
    subject { described_class.new('+', 0, 'element') }
    it { should_not be_deleting   }
    it { should     be_adding     }
    it { should_not be_unchanged  }
    it { should_not be_changed    }
    it { should_not be_finished_a }
    it { should_not be_finished_b }
  end

  describe "a delete" do
    subject { described_class.new('-', 0, 'element') }
    it { should     be_deleting   }
    it { should_not be_adding     }
    it { should_not be_unchanged  }
    it { should_not be_changed    }
    it { should_not be_finished_a }
    it { should_not be_finished_b }
  end

  describe "an unchanged" do
    subject { described_class.new('=', 0, 'element') }
    it { should_not be_deleting   }
    it { should_not be_adding     }
    it { should     be_unchanged  }
    it { should_not be_changed    }
    it { should_not be_finished_a }
    it { should_not be_finished_b }
  end

  describe "a changed" do
    subject { described_class.new('!', 0, 'element') }
    it { should_not be_deleting   }
    it { should_not be_adding     }
    it { should_not be_unchanged  }
    it { should     be_changed    }
    it { should_not be_finished_a }
    it { should_not be_finished_b }
  end

  describe "a finished_a" do
    subject { described_class.new('>', 0, 'element') }
    it { should_not be_deleting   }
    it { should_not be_adding     }
    it { should_not be_unchanged  }
    it { should_not be_changed    }
    it { should     be_finished_a }
    it { should_not be_finished_b }
  end

  describe "a finished_b" do
    subject { described_class.new('<', 0, 'element') }
    it { should_not be_deleting   }
    it { should_not be_adding     }
    it { should_not be_unchanged  }
    it { should_not be_changed    }
    it { should_not be_finished_a }
    it { should     be_finished_b }
  end
end

Version data entries

305 entries across 282 versions & 86 rubygems

Version Path
logstash-output-scalyr-0.2.1.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.2.0 vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.2.0.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.26.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.25.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.24.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.23.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.22.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.21.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.20.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.19.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.18.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.17.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.16.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.15.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.14.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.13 vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.12 vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.11.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb
logstash-output-scalyr-0.1.10.beta vendor/bundle/jruby/2.5.0/gems/diff-lcs-1.3/spec/change_spec.rb