Sha256: 342d9d8b80a8d963a72272639f7c167ce0f453df73319ea4eaabef5c5cdf7665

Contents?: true

Size: 609 Bytes

Versions: 1

Compression:

Stored size: 609 Bytes

Contents

require 'spec_helper'

describe Danica::Power do
  let(:variables) { [2, 4] }
  subject { described_class.new(*variables) }

  it_behaves_like 'an object that respond to basic_methods'
  it_behaves_like 'an object with basic operation'

  it_behaves_like 'a operator that has two terms', :power, {
    values: [ 3, 2 ],
    calculated: 9.0,
    to_tex: {
      string_expected: 'X1^{X2}',
      numeric_string_expected: '9',
      partial_string_expected: '3^{X2}'
    },
    to_gnu: {
      string_expected: 'X1**X2',
      numeric_string_expected: '9',
      partial_string_expected: '3**X2'
    }
  }
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
danica-2.0.4 spec/lib/danica/power_spec.rb