Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pandas/tests/io/conftest.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import os

import moto
import pytest
from pandas.io.parsers import read_table

Expand Down Expand Up @@ -42,6 +41,7 @@ def s3_resource(tips_file, jsonl_file):
is yielded by the fixture.
"""
pytest.importorskip('s3fs')
moto = pytest.importorskip('moto')
moto.mock_s3().start()

test_s3_files = [
Expand Down
3 changes: 2 additions & 1 deletion pandas/tests/io/json/test_compression.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import pytest
import moto

import pandas as pd
from pandas import compat
Expand Down Expand Up @@ -73,6 +72,8 @@ def test_read_zipped_json():
def test_with_s3_url(compression):
boto3 = pytest.importorskip('boto3')
pytest.importorskip('s3fs')
moto = pytest.importorskip('moto')

if compression == 'xz':
tm._skip_if_no_lzma()

Expand Down
2 changes: 1 addition & 1 deletion pandas/tests/io/test_excel.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import numpy as np
import pytest
from numpy import nan
import moto

import pandas as pd
import pandas.util.testing as tm
Expand Down Expand Up @@ -616,6 +615,7 @@ def test_read_from_http_url(self):
def test_read_from_s3_url(self):
boto3 = pytest.importorskip('boto3')
pytest.importorskip('s3fs')
moto = pytest.importorskip('moto')

with moto.mock_s3():
conn = boto3.resource("s3", region_name="us-east-1")
Expand Down