summaryrefslogtreecommitdiff
path: root/tiger-compiler/tests/testsuite/good/tested_function.tig
blob: e5cd6c2c55210ad0185ad2ce615ba5a0fa701713 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// add_5 should not be considered a unit test

function add_5(x: int): int = x + 5

function test_1() =
  (
    assert add_5(1) = 6
  )

function test_2() =
  (
    assert add_5(-1) = 4
  )

function test_3() =
  (
    assert add_5(0) = 5
  )