# Path: cap_client/utils.py
# class ColoredGroup(HelpColorsGroup):
# class NotRequiredIf(click.Option):
# class MultipleMutuallyExclusiveOptions(click.Option):
#     def __init__(self, *args, **kwargs):
# def make_tarfile(output_filename, source_dir):
# def validate_version(ctx, param, version_value):
# def load_json_from_file(ctx, param, value):
# def load_json(ctx, param, value):
#     def __init__(self, *args, **kwargs):
#     def handle_parse_result(self, ctx, opts, args):
#     def __init__(self, *args, **kwargs):
#     def handle_parse_result(self, ctx, opts, args):
# def logger(fun):
#     def wrapper(*args, **kwargs):
# def pid_option(required):
#     def inner_pid_option(fun):
#         def wrapper(*args, **kwargs):


import json
import responses
from tempfile import NamedTemporaryFile
from cap_client.utils import json_dumps
                "description": "Create an ALICE Analysis",
                "name": "ALICE Analysis"
            }],
            "email": "my_mail@cern.ch",
            "id": 1
        },
    )

    res = cli_run("analysis types")

    assert res.exit_code == 0
    assert res.stripped_output == json_dumps(
        ["atlas-workflows", "alice-analysis"])


@responses.activate
def test_analysis_types_when_no_types_for_this_user(cli_run):
    responses.add(
        responses.GET,
        "https://analysispreservation-dev.cern.ch/api/me",
        json={
            "deposit_groups": [],
            "email": "my_mail@cern.ch",
            "id": 1
        },
    )

    res = cli_run("analysis types")

    assert res.exit_code == 0

# Path: cap_client/utils.py
# class ColoredGroup(HelpColorsGroup):
# class NotRequiredIf(click.Option):
# class MultipleMutuallyExclusiveOptions(click.Option):
#     def __init__(self, *args, **kwargs):
# def make_tarfile(output_filename, source_dir):
# def validate_version(ctx, param, version_value):
# def load_json_from_file(ctx, param, value):
# def load_json(ctx, param, value):
#     def __init__(self, *args, **kwargs):
#     def handle_parse_result(self, ctx, opts, args):
#     def __init__(self, *args, **kwargs):
#     def handle_parse_result(self, ctx, opts, args):
# def logger(fun):
#     def wrapper(*args, **kwargs):
# def pid_option(required):
#     def inner_pid_option(fun):
#         def wrapper(*args, **kwargs):


# Path: tests/unit/test_analysis_cli.py
import json
import responses
from tempfile import NamedTemporaryFile
from cap_client.utils import json_dumps

                "description": "Create an ALICE Analysis",
                "name": "ALICE Analysis"
            }],
            "email": "my_mail@cern.ch",
            "id": 1
        },
    )

    res = cli_run("analysis types")

    assert res.exit_code == 0
    assert res.stripped_output == json_dumps(
        ["atlas-workflows", "alice-analysis"])


@responses.activate
def test_analysis_types_when_no_types_for_this_user(cli_run):
    responses.add(
        responses.GET,
        "https://analysispreservation-dev.cern.ch/api/me",
        json={
            "deposit_groups": [],
            "email": "my_mail@cern.ch",
            "id": 1
        },
    )

    res = cli_run("analysis types")

    assert res.exit_code == 0

    assert res.stripped_output == json_dumps([])