Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

67: Fix broken unit test(s) #68

Merged
merged 1 commit into from
Apr 23, 2024
Merged
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
15 changes: 8 additions & 7 deletions test/sasdataloader/utest_extension_registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@

logger = logging.getLogger(__name__)

BASE_URL = 'https://github.com/SasView/sasdata/raw/master/test/sasdataloader/data/'


def find(filename):
return os.path.join(os.path.dirname(__file__), 'data', filename)
Expand All @@ -24,23 +26,22 @@ def setUp(self):
# Local and remote files to compare loading
# NXcanSAS
self.valid_hdf_file = find("MAR07232_rest.h5")
self.valid_hdf_url = "https://github.com/SasView/sasdata/raw/master/test/sasdataloader/data/MAR07232_rest.h5"
self.valid_hdf_url = BASE_URL + "MAR07232_rest.h5"
# canSAS XML
self.valid_xml_file = find("valid_cansas_xml.xml")
self.valid_xml_url = "https://github.com/SasView/sasdata/raw/master/test/sasdataloader/data/valid_cansas_xml.xml"
self.valid_xml_url = BASE_URL + "valid_cansas_xml.xml"
# ASCII Text
self.valid_txt_file = find("avg_testdata.txt")
self.valid_txt_url = "https://github.com/SasView/sasdata/raw/master/test/sasdataloader/data/avg_testdata.txt"
self.valid_txt_url = BASE_URL + "avg_testdata.txt"
# ABS Text
self.valid_abs_file = find("ascii_test_4.abs")
self.valid_abs_url = "https://github.com/SasView/sasdata/raw/master/test/sasdataloader/data/ascii_test_4.abs"
self.valid_abs_url = BASE_URL + "ascii_test_4.abs"
# DAT 2D NIST format
self.valid_dat_file = find("detector_square.dat")
self.valid_dat_url = "https://github.com/SasView/sasdata/raw/master/test/sasdataloader/data/detector_square.dat"
self.valid_dat_url = BASE_URL + "detector_square.dat"
# Anton Parr SAXSess PDH format
# TODO: This should point to the sasdata package, but the file doesn't exist there yet.
self.valid_pdh_file = find("Anton-Paar.pdh")
self.valid_pdh_url = "https://github.com/SasView/sasview/raw/main/src/sas/example_data/1d_data/Anton-Paar.pdh"
self.valid_pdh_url = BASE_URL + "Anton-Paar.pdh"

self.valid_file_wrong_known_ext = find("valid_cansas_xml.txt")
self.valid_file_wrong_unknown_ext = find("valid_cansas_xml.xyz")
Expand Down
Loading