Add new acceptance test scenario: 053
``` × foo failed help: ┍━ left ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┑ │ Failed to deserialise PlutusData using UnConstrData: │ │ │ │ Con( │ │ Data( │ │ BigInt( │ │ Int( │ │ Int( │ │ Int { │ │ neg: false, │ │ val: 0, │ │ }, │ │ ), │ │ ), │ │ ), │ │ ), │ │ ) │ ┕━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┙ should be equal to ┍━ right ━━━━━━━━━┑ │ (con integer 3) │ ┕━━━━━━━━━━━━━━━━━┙ ```
This commit is contained in:
parent
95a62f7172
commit
c50bf94020
|
@ -0,0 +1,5 @@
|
||||||
|
# This file was generated by Aiken
|
||||||
|
# You typically do not need to edit this file
|
||||||
|
|
||||||
|
requirements = []
|
||||||
|
packages = []
|
|
@ -0,0 +1,3 @@
|
||||||
|
name = 'aiken-lang/acceptance_test_053'
|
||||||
|
version = '0.0.0'
|
||||||
|
description = ''
|
|
@ -0,0 +1,16 @@
|
||||||
|
pub type LinkedList<a> {
|
||||||
|
Empty
|
||||||
|
Node(a, LinkedList<a>)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn size(t: LinkedList<alg>) -> Int {
|
||||||
|
when t is {
|
||||||
|
Empty -> 0
|
||||||
|
Node(_, tail) -> 1 + size(tail)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
test foo() {
|
||||||
|
let xs = Node(0, Node(1, Node(2, Empty)))
|
||||||
|
size(xs) == 3
|
||||||
|
}
|
Loading…
Reference in New Issue