Mercurial > repos > public > sbplib
comparison MapTest.m @ 968:a4ad90b37998 feature/poroelastic
Merge with default.
author | Martin Almquist <malmquist@stanford.edu> |
---|---|
date | Sun, 23 Dec 2018 14:39:31 +0100 |
parents | a6c5e73ff44e |
children |
comparison
equal
deleted
inserted
replaced
967:368a2773f78b | 968:a4ad90b37998 |
---|---|
8 struct(), [1; 3; 4]; | 8 struct(), [1; 3; 4]; |
9 [1,2; 4 3], struct(); | 9 [1,2; 4 3], struct(); |
10 'Hej', struct('lol', 6); | 10 'Hej', struct('lol', 6); |
11 0, 'Nej'; | 11 0, 'Nej'; |
12 }; | 12 }; |
13 end | |
14 | |
15 function testMultiKey(testCase) | |
16 map = Map | |
17 | |
18 function setMultiKey() | |
19 map(1,2) = 1; | |
20 end | |
21 | |
22 function getMultiKey() | |
23 v = map(1,2); | |
24 end | |
25 | |
26 testCase.verifyError(@setMultiKey,'sbplib:Map:multipleKeys') | |
27 testCase.verifyError(@getMultiKey,'sbplib:Map:multipleKeys') | |
13 end | 28 end |
14 | 29 |
15 function testSetAndGet(testCase) | 30 function testSetAndGet(testCase) |
16 keyValuePairs = getKeyValuePairs(); | 31 keyValuePairs = getKeyValuePairs(); |
17 | 32 |