From c7bbd7be945998f4471b95a5c0f54af75dfb922c Mon Sep 17 00:00:00 2001 From: Benjamin Peterson Date: Tue, 21 Feb 2012 00:15:10 -0500 Subject: don't rely on dict order --- Lib/lib-tk/test/test_ttk/test_functions.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Lib/lib-tk/test/test_ttk/test_functions.py b/Lib/lib-tk/test/test_ttk/test_functions.py index 9de25a4..15e76c1 100644 --- a/Lib/lib-tk/test/test_ttk/test_functions.py +++ b/Lib/lib-tk/test/test_ttk/test_functions.py @@ -143,8 +143,10 @@ class InternalFunctionsTest(unittest.TestCase): self.assertEqual(ttk._format_elemcreate('image', False, 'test', ('a', 'b', 'c')), ("test {a b} c", ())) # state spec and options - self.assertEqual(ttk._format_elemcreate('image', False, 'test', - ('a', 'b'), a='x', b='y'), ("test a b", ("-a", "x", "-b", "y"))) + res = ttk._format_elemcreate('image', False, 'test', + ('a', 'b'), a='x', b='y') + self.assertEqual(res[0], "test a b") + self.assertEqual(set(res[1]), {"-a", "x", "-b", "y"}) # format returned values as a tcl script # state spec with multiple states and an option with a multivalue self.assertEqual(ttk._format_elemcreate('image', True, 'test', -- cgit v0.12