Sha256: fa0065cbaef4fba28ffada10d0f002e2fdba1a1235911093983182c64f7a2d0b

Contents?: true

Size: 413 Bytes

Versions: 7

Compression:

Stored size: 413 Bytes

Contents

#!/bin/env ruby
# encoding: utf-8
require 'minitest_helper'

class TestSigma < TestInterpreterBase
  def setup
  end

  def test_general
    assert_iq_equal(
      '∑[x=0,10] x',
      '55.0'
    )

    assert_iq_equal(
      '∑[i=1, 10] i',
      '55.0'
    )

    assert_iq_equal(
      '∑[x=0, 10] x^2',
      '385.0'
    )

    assert_iq_equal(
      '∑[x=0, 10] x^3',
      '3025.0'
    )

  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
hilbert-0.0.2700420 test/interpreter/test_sigma.rb
hilbert-0.0.2700410 test/interpreter/test_sigma.rb
hilbert-0.0.2700400 test/interpreter/test_sigma.rb
hilbert-0.0.2700320 test/interpreter/test_sigma.rb
hilbert-0.0.2700300 test/interpreter/test_sigma.rb
hilbert-0.0.2700210 test/interpreter/test_sigma.rb
hilbert-0.0.2700110 test/interpreter/test_sigma.rb