def METHOD_NAME(self, casting_dtype):
    expected_exc = TypeError
    casting, dtype = casting_dtype
    A_np = np.ones((2, 4))
    B_np = np.ones((4, 3))
    A_num = num.ones((2, 4))
    B_num = num.ones((4, 3))
    with pytest.raises(expected_exc):
        np.matmul(A_np, B_np, casting=casting, dtype=dtype)
    with pytest.raises(expected_exc):
        num.matmul(A_num, B_num, casting=casting, dtype=dtype)