MCPcopy Index your code
hub / github.com/python/cpython / test_setupapp

Method test_setupapp

Lib/idlelib/idle_test/test_macosx.py:99–109  ·  view source on GitHub ↗

Call setupApp with each possible graphics type.

(self, overrideRootMenu)

Source from the content-addressed store, hash-verified

97
98 @mock.patch('idlelib.macosx.overrideRootMenu') #27312
99 def test_setupapp(self, overrideRootMenu):
100 "Call setupApp with each possible graphics type."
101 root = self.root
102 flist = FileList(root)
103 for tktype in alltypes:
104 with self.subTest(tktype=tktype):
105 macosx._tk_type = tktype
106 macosx.setupApp(root, flist)
107 if tktype in ('carbon', 'cocoa'):
108 self.assertTrue(overrideRootMenu.called)
109 overrideRootMenu.reset_mock()
110
111
112if __name__ == '__main__':

Callers

nothing calls this directly

Calls 4

FileListClass · 0.90
assertTrueMethod · 0.80
subTestMethod · 0.45
reset_mockMethod · 0.45

Tested by

no test coverage detected