1. allison
  2. pynie


allisonrandal  committed 4784e16

Add tests for dictionaries.

  • Participants
  • Parent commits 5ae80a2
  • Branches default

Comments (0)

Files changed (2)

File Lib/test/bootstrap/dicts.py

View file
+print('test: one element dict')
+a = {"foo":1}
+if a: print('success: one element dict')
+else: print('failure: one element dict')
+print('test: display dict element')
+b = a['foo']
+if b == 1: print('success: display dict element')
+else: print('failure: display dict element')
+print("test: display dict {'foo': 1}")
+print("success: display dict", a)
+print('test: add element to dict')
+a['bar'] = "baz"
+b = a['bar']
+if b == 'baz': print('success: add element to dict')
+else: print('failure: add element to dict')

File runtests.py

View file
     def test_13_exceptions(self):
+    def test_14_dicts(self):
+        """Lib/test/bootstrap/dicts.py"""
     def test_math_ops_compare(self):