From 1d28c14d492f6a5783f2ccd3127297e2885e2d32 Mon Sep 17 00:00:00 2001 From: Dustin Voss Date: Sat, 7 Dec 2013 19:25:38 -0800 Subject: [PATCH] =?UTF-8?q?Collections=20test=20suite=20was=20incorrect=20?= =?UTF-8?q?for=20=E2=80=9Celement=E2=80=9D:=20the=20return=20value=20does?= =?UTF-8?q?=20not=20need=20to=20be=20the=20element=20type=20of=20the=20col?= =?UTF-8?q?lection=20if=20=E2=80=9Cdefault:=E2=80=9D=20is=20used.=20Collec?= =?UTF-8?q?tions=20test=20suite=20was=20too=20strict=20with=20add!=20and?= =?UTF-8?q?=20remove!:=20OD=20implements=20them=20on=20,=20not?= =?UTF-8?q?=20just=20.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sources/dylan/tests/collections.dylan | 6 +++--- sources/dylan/tests/specification.dylan | 6 ++++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/sources/dylan/tests/collections.dylan b/sources/dylan/tests/collections.dylan index 62c1c8cdc8..dd6f2f7a88 100644 --- a/sources/dylan/tests/collections.dylan +++ b/sources/dylan/tests/collections.dylan @@ -834,9 +834,9 @@ define method test-element element(collection, -1, default: default), default); unless (type == ) - check-condition(format-to-string("%s element wrong default type errors", name), - , - element(collection, -1, default: #"wrong-default-type")); + check-equal(format-to-string("%s element wrong default type allowed", name), + element(collection, -1, default: #"wrong-default-type"), + #"wrong-default-type"); end unless; for (key in key-sequence(collection)) check-equal(format-to-string("%s element %=", name, key), diff --git a/sources/dylan/tests/specification.dylan b/sources/dylan/tests/specification.dylan index 5fa19b5953..2b6ac6c819 100644 --- a/sources/dylan/tests/specification.dylan +++ b/sources/dylan/tests/specification.dylan @@ -280,15 +280,17 @@ define protocol-spec collections () function head-setter (, ) => (); function tail-setter (, ) => (); open generic-function add (, ) => (); - open generic-function add! (, ) => (); + //--- DRM defines add! for , but OD supports it for all . + open generic-function add! (, ) => (); open generic-function add-new (, , #"key", #"test") => (); open generic-function add-new! (, , #"key", #"test") => (); open generic-function remove (, , #"key", #"test", #"count") => (); + //--- DRM defines remove! for , but OD supports it for all . open generic-function remove! - (, , #"key", #"test", #"count") => (); + (, , #"key", #"test", #"count") => (); open generic-function push (, ) => (); open generic-function pop () => (); open generic-function push-last (, ) => ();