def test_register_with_primary(self):
        AdminWidgetHook(extension=self.extension, widget_cls=TestWidget,
                        primary=True)

        self.assertIn(TestWidget, primary_widgets)
Testing AdminWidgetHook initializing with primary set
dataset/ETHPy150Open reviewboard/reviewboard/reviewboard/extensions/tests.py/AdminWidgetHookTests.test_register_with_primary