Francois Gouget : testbot: Make sure optional enum properties are not used.
Alexandre Julliard
julliard at winehq.org
Mon Jun 4 15:43:21 CDT 2018
Module: tools
Branch: master
Commit: b2b0fc1063f5f5e0d58ccbab2181f43d3f1c0a50
URL: https://source.winehq.org/git/tools.git/?a=commit;h=b2b0fc1063f5f5e0d58ccbab2181f43d3f1c0a50
Author: Francois Gouget <fgouget at codeweavers.com>
Date: Mon Jun 4 20:06:36 2018 +0200
testbot: Make sure optional enum properties are not used.
They are not supported and trying to set them to an undefined value
will trigger errors.
Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
testbot/lib/ObjectModel/EnumPropertyDescriptor.pm | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/testbot/lib/ObjectModel/EnumPropertyDescriptor.pm b/testbot/lib/ObjectModel/EnumPropertyDescriptor.pm
index d585069..d8f0d39 100644
--- a/testbot/lib/ObjectModel/EnumPropertyDescriptor.pm
+++ b/testbot/lib/ObjectModel/EnumPropertyDescriptor.pm
@@ -42,6 +42,10 @@ sub _initialize($$)
$self->{Class} = "Enum";
$self->{Values} = $Values;
+ if (!$self->{IsRequired})
+ {
+ die "Optional enum properties are not supported\n";
+ }
$self->SUPER::_initialize();
}
More information about the wine-cvs
mailing list