diff options
| author | Jérémy Zurcher <jeremy@asynk.ch> | 2012-06-02 19:08:53 +0200 | 
|---|---|---|
| committer | Jérémy Zurcher <jeremy@asynk.ch> | 2012-06-02 19:08:53 +0200 | 
| commit | 00f3bc3b9d4e74d089a76d1a31f74f3a4207b541 (patch) | |
| tree | 09e8b20b480866a058571083643e29d53607510a /tests | |
| parent | 722cc78e6f2105108225212a0960f1b928fa71f2 (diff) | |
| download | edoors-00f3bc3b9d4e74d089a76d1a31f74f3a4207b541.zip edoors-00f3bc3b9d4e74d089a76d1a31f74f3a4207b541.tar.gz  | |
add eiotas_particle_destination_set and tests
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/particle.c | 11 | 
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/particle.c b/tests/particle.c index 199df27..60837ac 100644 --- a/tests/particle.c +++ b/tests/particle.c @@ -134,6 +134,17 @@ void test_particle()      check_str((char*)p2->cur_room,"room/room","room is wrong");      p3 = eiotas_require_particle(dom0); +    eiotas_particle_destinations_add(p3,"dom0/room0/room1/doorx?get,door?get,dom0/room0/door0?get"); +    eiotas_particle_split_dst(p3); +    check_str((char*)p3->cur_action,"get","action is wrong"); +    check_str((char*)p3->cur_door,"doorx","door is wrong"); +    check_str((char*)p3->cur_room,"dom0/room0/room1","room is wrong"); +    eiotas_particle_destination_set(p3,"  room/door?got  nothing else matters "); +    eiotas_particle_split_dst(p3); +    check_str((char*)p3->cur_action,"got","action is wrong"); +    check_str((char*)p3->cur_door,"door","door is wrong"); +    check_str((char*)p3->cur_room,"room","room is wrong"); +      p4 = eiotas_require_particle(dom0);      eiotas_particle_merge(p0,p1);      eiotas_particle_merge(p0,p2);  | 
