Sha256: 0bbca916db42b7485b6f4202cb708ccd5ef028ff95ba53fbc7d362bf9f22ace3

Contents?: true

Size: 739 Bytes

Versions: 3

Compression:

Stored size: 739 Bytes

Contents

# frozen_string_literal: true

module Danica
  module VariablesHolder
    class Dummy
      include Common
      include VariablesHolder

      variables :x, y: { latex: '\y' }, z: 10

      delegate :to, :to_f, to: :block

      def block
        x**y + z
      end
    end

    class DummyChild < Dummy
      variables :k, z: { name: 'zeta' }
    end

    class DummyOverwrite < Dummy
      variables :w
      reset_variables
      variables :k, z: { name: 'zeta' }
    end

    class DummyAlias < Dummy
      variable_alias :x, :a
    end
  end
end

module Danica
  module VariablesHolder
    class DummyString
      include Common
      include VariablesHolder

      variables 'x', 'y' => { latex: '\y' }, 'z' => 10
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
danica-2.7.7 spec/support/models/variables_holder/dummy.rb
danica-2.7.6 spec/support/models/variables_holder/dummy.rb
danica-2.7.5 spec/support/models/variables_holder/dummy.rb