from collections import namedtuple

import pytest

from .barrier import *
from .bec import *
from .bragg import *
from .paint_1d import *
from .transistor import *


@pytest.fixture
def job_fixtures(
    pending_bec_job,
    running_bec_job,
    complete_bec_job,
    failed_bec_job,
    pending_bec_batch_job,
    running_bec_batch_job,
    complete_bec_batch_job,
    failed_bec_batch_job,
    pending_bec_job_response,
    running_bec_job_response,
    complete_bec_job_response,
    failed_bec_job_response,
    pending_bec_batch_job_response,
    running_bec_batch_job_response,
    complete_bec_batch_job_response,
    failed_bec_batch_job_response,
    pending_barrier_job,
    running_barrier_job,
    complete_barrier_job,
    failed_barrier_job,
    pending_barrier_batch_job,
    running_barrier_batch_job,
    complete_barrier_batch_job,
    failed_barrier_batch_job,
    pending_barrier_job_response,
    running_barrier_job_response,
    complete_barrier_job_response,
    failed_barrier_job_response,
    pending_barrier_batch_job_response,
    running_barrier_batch_job_response,
    complete_barrier_batch_job_response,
    failed_barrier_batch_job_response,
    pending_transistor_job,
    running_transistor_job,
    complete_transistor_job,
    failed_transistor_job,
    pending_transistor_batch_job,
    running_transistor_batch_job,
    complete_transistor_batch_job,
    failed_transistor_batch_job,
    pending_transistor_job_response,
    running_transistor_job_response,
    complete_transistor_job_response,
    failed_transistor_job_response,
    pending_transistor_batch_job_response,
    running_transistor_batch_job_response,
    complete_transistor_batch_job_response,
    failed_transistor_batch_job_response,
    pending_bragg_job,
    running_bragg_job,
    complete_bragg_job,
    failed_bragg_job,
    pending_bragg_batch_job,
    running_bragg_batch_job,
    complete_bragg_batch_job,
    failed_bragg_batch_job,
    pending_bragg_job_response,
    running_bragg_job_response,
    complete_bragg_job_response,
    failed_bragg_job_response,
    pending_bragg_batch_job_response,
    running_bragg_batch_job_response,
    complete_bragg_batch_job_response,
    failed_bragg_batch_job_response,
    pending_paint_1d_job,
    running_paint_1d_job,
    complete_paint_1d_job,
    failed_paint_1d_job,
    pending_paint_1d_batch_job,
    running_paint_1d_batch_job,
    complete_paint_1d_batch_job,
    failed_paint_1d_batch_job,
    pending_paint_1d_job_response,
    running_paint_1d_job_response,
    complete_paint_1d_job_response,
    failed_paint_1d_job_response,
    pending_paint_1d_batch_job_response,
    running_paint_1d_batch_job_response,
    complete_paint_1d_batch_job_response,
    failed_paint_1d_batch_job_response,
):
    JobFixtures = namedtuple(
        "JobFixtures",
        [
            "pending_bec_job",
            "running_bec_job",
            "complete_bec_job",
            "failed_bec_job",
            "pending_bec_batch_job",
            "running_bec_batch_job",
            "complete_bec_batch_job",
            "failed_bec_batch_job",
            "pending_bec_job_response",
            "running_bec_job_response",
            "complete_bec_job_response",
            "failed_bec_job_response",
            "pending_bec_batch_job_response",
            "running_bec_batch_job_response",
            "complete_bec_batch_job_response",
            "failed_bec_batch_job_response",
            "pending_barrier_job",
            "running_barrier_job",
            "complete_barrier_job",
            "failed_barrier_job",
            "pending_barrier_batch_job",
            "running_barrier_batch_job",
            "complete_barrier_batch_job",
            "failed_barrier_batch_job",
            "pending_barrier_job_response",
            "running_barrier_job_response",
            "complete_barrier_job_response",
            "failed_barrier_job_response",
            "pending_barrier_batch_job_response",
            "running_barrier_batch_job_response",
            "complete_barrier_batch_job_response",
            "failed_barrier_batch_job_response",
            "pending_transistor_job",
            "running_transistor_job",
            "complete_transistor_job",
            "failed_transistor_job",
            "pending_transistor_batch_job",
            "running_transistor_batch_job",
            "complete_transistor_batch_job",
            "failed_transistor_batch_job",
            "pending_transistor_job_response",
            "running_transistor_job_response",
            "complete_transistor_job_response",
            "failed_transistor_job_response",
            "pending_transistor_batch_job_response",
            "running_transistor_batch_job_response",
            "complete_transistor_batch_job_response",
            "failed_transistor_batch_job_response",
            "pending_bragg_job",
            "running_bragg_job",
            "complete_bragg_job",
            "failed_bragg_job",
            "pending_bragg_batch_job",
            "running_bragg_batch_job",
            "complete_bragg_batch_job",
            "failed_bragg_batch_job",
            "pending_bragg_job_response",
            "running_bragg_job_response",
            "complete_bragg_job_response",
            "failed_bragg_job_response",
            "pending_bragg_batch_job_response",
            "running_bragg_batch_job_response",
            "complete_bragg_batch_job_response",
            "failed_bragg_batch_job_response",
            "pending_paint_1d_job",
            "running_paint_1d_job",
            "complete_paint_1d_job",
            "failed_paint_1d_job",
            "pending_paint_1d_batch_job",
            "running_paint_1d_batch_job",
            "complete_paint_1d_batch_job",
            "failed_paint_1d_batch_job",
            "pending_paint_1d_job_response",
            "running_paint_1d_job_response",
            "complete_paint_1d_job_response",
            "failed_paint_1d_job_response",
            "pending_paint_1d_batch_job_response",
            "running_paint_1d_batch_job_response",
            "complete_paint_1d_batch_job_response",
            "failed_paint_1d_batch_job_response",
        ],
    )
    yield JobFixtures(
        pending_bec_job,
        running_bec_job,
        complete_bec_job,
        failed_bec_job,
        pending_bec_batch_job,
        running_bec_batch_job,
        complete_bec_batch_job,
        failed_bec_batch_job,
        pending_bec_job_response,
        running_bec_job_response,
        complete_bec_job_response,
        failed_bec_job_response,
        pending_bec_batch_job_response,
        running_bec_batch_job_response,
        complete_bec_batch_job_response,
        failed_bec_batch_job_response,
        pending_barrier_job,
        running_barrier_job,
        complete_barrier_job,
        failed_barrier_job,
        pending_barrier_batch_job,
        running_barrier_batch_job,
        complete_barrier_batch_job,
        failed_barrier_batch_job,
        pending_barrier_job_response,
        running_barrier_job_response,
        complete_barrier_job_response,
        failed_barrier_job_response,
        pending_barrier_batch_job_response,
        running_barrier_batch_job_response,
        complete_barrier_batch_job_response,
        failed_barrier_batch_job_response,
        pending_transistor_job,
        running_transistor_job,
        complete_transistor_job,
        failed_transistor_job,
        pending_transistor_batch_job,
        running_transistor_batch_job,
        complete_transistor_batch_job,
        failed_transistor_batch_job,
        pending_transistor_job_response,
        running_transistor_job_response,
        complete_transistor_job_response,
        failed_transistor_job_response,
        pending_transistor_batch_job_response,
        running_transistor_batch_job_response,
        complete_transistor_batch_job_response,
        failed_transistor_batch_job_response,
        pending_bragg_job,
        running_bragg_job,
        complete_bragg_job,
        failed_bragg_job,
        pending_bragg_batch_job,
        running_bragg_batch_job,
        complete_bragg_batch_job,
        failed_bragg_batch_job,
        pending_bragg_job_response,
        running_bragg_job_response,
        complete_bragg_job_response,
        failed_bragg_job_response,
        pending_bragg_batch_job_response,
        running_bragg_batch_job_response,
        complete_bragg_batch_job_response,
        failed_bragg_batch_job_response,
        pending_paint_1d_job,
        running_paint_1d_job,
        complete_paint_1d_job,
        failed_paint_1d_job,
        pending_paint_1d_batch_job,
        running_paint_1d_batch_job,
        complete_paint_1d_batch_job,
        failed_paint_1d_batch_job,
        pending_paint_1d_job_response,
        running_paint_1d_job_response,
        complete_paint_1d_job_response,
        failed_paint_1d_job_response,
        pending_paint_1d_batch_job_response,
        running_paint_1d_batch_job_response,
        complete_paint_1d_batch_job_response,
        failed_paint_1d_batch_job_response,
    )
