Skip to content

Commit

Permalink
updated test_store.py
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeqfu committed May 30, 2020
1 parent 69a516a commit 7b6a647
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions tests/test_store.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
# store.py

import numpy as np
import pandas as pd

from pyhelpers.dir import cd
from pyhelpers.store import load_feather, load_pickle, save_feather, save_pickle
from pyhelpers.store import *

xy_array = np.array([(530034, 180381), # London
(406689, 286822), # Birmingham
(383819, 398052), # Manchester
(582044, 152953)]) # Leeds
dat = pd.DataFrame(xy_array, columns=['Easting', 'Northing'])

path_to_test_pickle = cd("tests", "data", "dat.pickle") # cd("tests\\data\\dat.pickle")
print(path_to_test_pickle) # >>> C:\Users\fuq\DataShare\Experiments\pyhelpers\tests\data\dat.pickle
path_to_test_pickle = cd("tests", "data", "dat.pickle") # path_to_test_pickle == cd("tests\\data\\dat.pickle")
print(path_to_test_pickle) # C:\Users\fuq\DataShare\Experiments\pyhelpers\tests\data\dat.pickle

# Save dat as a pickle file
save_pickle(dat, path_to_test_pickle, verbose=True)
Expand Down

0 comments on commit 7b6a647

Please sign in to comment.