Skip to content

Commit

Permalink
Maint: Do not pass literal json to read_json in test (#3221)
Browse files Browse the repository at this point in the history
  • Loading branch information
binste authored Oct 9, 2023
1 parent ef4b86e commit bcae0f1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/utils/test_utils.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import pytest
import warnings
import io
import json
import warnings

import numpy as np
import pandas as pd
import pytest

from altair.utils import infer_vegalite_type, sanitize_dataframe

Expand Down Expand Up @@ -68,7 +69,7 @@ def test_sanitize_dataframe():
print(s)

# Re-construct pandas dataframe
df2 = pd.read_json(s)
df2 = pd.read_json(io.StringIO(s))

# Re-order the columns to match df
df2 = df2[df.columns]
Expand Down

0 comments on commit bcae0f1

Please sign in to comment.