# Path: freesas/test/utilstests.py
# def get_datafile(name):
#     """Provides the full path of a test file,
#     downloading it from the internet if needed
# 
#     :param name: name of the file to get
#     :return: full path of the datafile
#     """
#     logger.info(f"Download file {name}")
#     fullpath = downloader.getfile(name)
#     return fullpath


import unittest
import pathlib
import logging
from subprocess import run, PIPE, STDOUT
from os import linesep
from os.path import normpath
from platform import system
from freesas.test.utilstests import get_datafile
"""End to end tests for auto_gpa.py """

__authors__ = ["Martha Brennich"]
__license__ = "MIT"
__date__ = "16/07/2021"

logger = logging.getLogger(__name__)


class TestFreeSAS(unittest.TestCase):
    cwd = pathlib.Path.cwd()
    test_location = pathlib.Path(__file__)
    test_data_location = pathlib.Path(test_location.parent, "e2etest_data")
    bsa_filename = pathlib.Path(get_datafile("bsa_005_sub.dat"))

# Path: freesas/test/utilstests.py
# def get_datafile(name):
#     """Provides the full path of a test file,
#     downloading it from the internet if needed
# 
#     :param name: name of the file to get
#     :return: full path of the datafile
#     """
#     logger.info(f"Download file {name}")
#     fullpath = downloader.getfile(name)
#     return fullpath


# Path: e2etest/e2etest_guinier_apps.py
import unittest
import pathlib
import logging
from subprocess import run, PIPE, STDOUT
from os import linesep
from os.path import normpath
from platform import system
from freesas.test.utilstests import get_datafile

"""End to end tests for auto_gpa.py """

__authors__ = ["Martha Brennich"]
__license__ = "MIT"
__date__ = "16/07/2021"

logger = logging.getLogger(__name__)


class TestFreeSAS(unittest.TestCase):
    cwd = pathlib.Path.cwd()
    test_location = pathlib.Path(__file__)
    test_data_location = pathlib.Path(test_location.parent, "e2etest_data")
    bsa_filename = pathlib.Path(get_datafile("bsa_005_sub.dat"))

    sas_curve2_filename = pathlib.Path(get_datafile( "SASDF52.dat"))