Skip to content

Commit 93815a5

Browse files
authored
Remove unused variable gmt_version from three tests (#1766)
1 parent 3728994 commit 93815a5

File tree

3 files changed

+3
-15
lines changed

3 files changed

+3
-15
lines changed

pygmt/tests/test_grdtrack.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,14 @@
66
import numpy.testing as npt
77
import pandas as pd
88
import pytest
9-
from packaging.version import Version
10-
from pygmt import clib, grdtrack, which
9+
from pygmt import grdtrack, which
1110
from pygmt.datasets import load_earth_relief, load_ocean_ridge_points
1211
from pygmt.exceptions import GMTInvalidInput
1312
from pygmt.helpers import data_kind
1413

1514
TEST_DATA_DIR = os.path.join(os.path.dirname(__file__), "data")
1615
TEMP_TRACK = os.path.join(TEST_DATA_DIR, "tmp_track.txt")
1716

18-
with clib.Session() as _lib:
19-
gmt_version = Version(_lib.info["version"])
20-
2117

2218
@pytest.fixture(scope="module", name="dataarray")
2319
def fixture_dataarray():

pygmt/tests/test_plot.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,13 @@
99
import pandas as pd
1010
import pytest
1111
import xarray as xr
12-
from packaging.version import Version
13-
from pygmt import Figure, clib
12+
from pygmt import Figure
1413
from pygmt.exceptions import GMTInvalidInput
1514
from pygmt.helpers import GMTTempFile
1615

1716
TEST_DATA_DIR = os.path.join(os.path.dirname(__file__), "data")
1817
POINTS_DATA = os.path.join(TEST_DATA_DIR, "points.txt")
1918

20-
with clib.Session() as _lib:
21-
gmt_version = Version(_lib.info["version"])
22-
2319

2420
@pytest.fixture(scope="module")
2521
def data():

pygmt/tests/test_velo.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,9 @@
33
"""
44
import pandas as pd
55
import pytest
6-
from packaging.version import Version
7-
from pygmt import Figure, clib
6+
from pygmt import Figure
87
from pygmt.exceptions import GMTInvalidInput
98

10-
with clib.Session() as _lib:
11-
gmt_version = Version(_lib.info["version"])
12-
139

1410
@pytest.fixture(scope="module", name="dataframe")
1511
def fixture_dataframe():

0 commit comments

Comments
 (0)