test: add slice tests

This commit is contained in:
Ayke van Laethem
2018-10-18 15:02:53 +02:00
parent 72390c21cb
commit f9edf7cc5c
2 changed files with 35 additions and 0 deletions
+6
View File
@@ -0,0 +1,6 @@
foo: len=4 cap=4 data: 1 2 4 5
bar: len=3 cap=5 data: 0 0 0
foo[1:2]: len=1 cap=3 data: 2
sum foo: 12
copy foo -> bar: 3
bar: len=3 cap=5 data: 1 2 4