def test_args_extra_expects_a_list_or_a_tuple(self):
        inst = Sijax()

        def try_args(args_extra, should_succeed):
            success = False
            try:
                inst.register_callback("name", lambda r: r, args_extra=args_extra)
                success = True
            except SijaxError:
                pass

            self.assertEqual(should_succeed, success, repr(args_extra) % "Failure for %s")

        # A list, a tuple and None should all work
        try_args([], True)
        try_args((), True)
        try_args(None, True)
        try_args(['one item'], True)
        try_args(('one item',), True)
        try_args(['one', 'two'], True)
        try_args(('one', 'two'), True)
        try_args([{"dictionary": "in", "the": "list"}], True)
        try_args(({"dictionary": "in", "the": "tuple"},), True)

        try_args('string', False)
        try_args(True, False)
        try_args(False, False)
        try_args({"dictionary": "here"}, False)
dataset/ETHPy150Open spantaleev/sijax-python/tests/sijax_tests.py/SijaxMainTestCase.test_args_extra_expects_a_list_or_a_tuple/swapped operands of `%`