From 49231e6f2a69750e8e97e5b8690aec7f7f160fe9 Mon Sep 17 00:00:00 2001 From: Bryn Pickering <17178478+brynpickering@users.noreply.github.com> Date: Wed, 25 Oct 2023 09:41:30 +0100 Subject: [PATCH] Pre-commit run all --- tests/conftest.py | 1 - tests/test_backend_helper_functions.py | 1 - tests/test_backend_parsing.py | 3 +-- tests/test_backend_pyomo.py | 3 +-- tests/test_backend_where_parser.py | 1 - tests/test_model_data.py | 3 +-- tests/test_model_manipulation.py | 1 - 7 files changed, 3 insertions(+), 10 deletions(-) diff --git a/tests/conftest.py b/tests/conftest.py index 56a9529df..9ddc2f4ac 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -3,7 +3,6 @@ import numpy as np import pytest import xarray as xr - from calliope import AttrDict from calliope.backend import latex_backend_model, pyomo_backend_model diff --git a/tests/test_backend_helper_functions.py b/tests/test_backend_helper_functions.py index 95fa20046..6726c5870 100644 --- a/tests/test_backend_helper_functions.py +++ b/tests/test_backend_helper_functions.py @@ -1,7 +1,6 @@ import numpy as np import pytest import xarray as xr - from calliope import exceptions from calliope.backend import helper_functions diff --git a/tests/test_backend_parsing.py b/tests/test_backend_parsing.py index 75f81b4f6..4639b11ac 100644 --- a/tests/test_backend_parsing.py +++ b/tests/test_backend_parsing.py @@ -2,11 +2,10 @@ from io import StringIO from unittest.mock import patch +import calliope import pyparsing as pp import pytest import ruamel.yaml as yaml - -import calliope from calliope.backend import backend_model, expression_parser, parsing, where_parser from .common.util import check_error_or_warning diff --git a/tests/test_backend_pyomo.py b/tests/test_backend_pyomo.py index 961061f04..acef7f429 100755 --- a/tests/test_backend_pyomo.py +++ b/tests/test_backend_pyomo.py @@ -3,13 +3,12 @@ from copy import deepcopy from itertools import product +import calliope.exceptions as exceptions import numpy as np import pandas as pd import pyomo.kernel as pmo import pytest # noqa: F401 import xarray as xr - -import calliope.exceptions as exceptions from calliope.backend.pyomo_backend_model import PyomoBackendModel from calliope.core.attrdict import AttrDict diff --git a/tests/test_backend_where_parser.py b/tests/test_backend_where_parser.py index fcef894b9..5cfedf691 100644 --- a/tests/test_backend_where_parser.py +++ b/tests/test_backend_where_parser.py @@ -2,7 +2,6 @@ import pyparsing import pytest import xarray as xr - from calliope.backend import expression_parser, helper_functions, where_parser from calliope.core.attrdict import AttrDict from calliope.exceptions import BackendError diff --git a/tests/test_model_data.py b/tests/test_model_data.py index d63a251a0..a1b2389a3 100644 --- a/tests/test_model_data.py +++ b/tests/test_model_data.py @@ -1,11 +1,10 @@ import logging from pathlib import Path +import calliope.exceptions as exceptions import numpy as np import pandas as pd import pytest - -import calliope.exceptions as exceptions from calliope._version import __version__ from calliope.core.attrdict import AttrDict from calliope.preprocess import model_run_from_yaml diff --git a/tests/test_model_manipulation.py b/tests/test_model_manipulation.py index 65a9b489a..b51cf83ba 100644 --- a/tests/test_model_manipulation.py +++ b/tests/test_model_manipulation.py @@ -1,5 +1,4 @@ import pytest # noqa: F401 - from calliope import exceptions from .common.util import build_test_model as build_model