None
Test: ingestor|bifrost|dataset_found_is_not_old|
None
None
None
None
None
None
None
None
None
None
None
None
None
instrument = 'bifrost', coda_proposal_id = '977695'
def test_dataset_found_is_not_old(
instrument: str,
coda_proposal_id: str,
) -> None:
ds = scicat.get_latest_coda_dataset(
instrument=instrument, proposal_id=coda_proposal_id
)
creation_time = cast(datetime, ds.creation_time)
> assert creation_time > datetime.now(creation_time.tzinfo) - timedelta(hours=24)
E assert datetime.datetime(2025, 8, 30, 8, 34, 29, 949000, tzinfo=tzutc()) > (datetime.datetime(2025, 8, 31, 22, 22, 47, 543496, tzinfo=tzutc()) - datetime.timedelta(days=1))
E + where datetime.datetime(2025, 8, 31, 22, 22, 47, 543496, tzinfo=tzutc()) =
E + where
E + and tzutc() = datetime.datetime(2025, 8, 30, 8, 34, 29, 949000, tzinfo=tzutc()).tzinfo
E + and datetime.timedelta(days=1) = timedelta(hours=24)
tests/ingestor/ingestor_test.py:57: AssertionError
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
instrument = 'bifrost', coda_proposal_id = '977695'
def test_dataset_found_is_not_old(
instrument: str,
coda_proposal_id: str,
) -> None:
ds = scicat.get_latest_coda_dataset(
instrument=instrument, proposal_id=coda_proposal_id
)
creation_time = cast(datetime, ds.creation_time)
> assert creation_time > datetime.now(creation_time.tzinfo) - timedelta(hours=24)
E assert datetime.datetime(2025, 7, 25, 10, 2, 35, 234000, tzinfo=tzutc()) > (datetime.datetime(2025, 7, 28, 22, 16, 41, 710961, tzinfo=tzutc()) - datetime.timedelta(days=1))
E + where datetime.datetime(2025, 7, 28, 22, 16, 41, 710961, tzinfo=tzutc()) =
E + where
E + and tzutc() = datetime.datetime(2025, 7, 25, 10, 2, 35, 234000, tzinfo=tzutc()).tzinfo
E + and datetime.timedelta(days=1) = timedelta(hours=24)
tests/ingestor/ingestor_test.py:57: AssertionError
instrument = 'bifrost', coda_proposal_id = '977695'
def test_dataset_found_is_not_old(
instrument: str,
coda_proposal_id: str,
) -> None:
ds = scicat.get_latest_coda_dataset(
instrument=instrument, proposal_id=coda_proposal_id
)
creation_time = cast(datetime, ds.creation_time)
> assert creation_time > datetime.now(creation_time.tzinfo) - timedelta(hours=24)
E assert datetime.datetime(2025, 7, 25, 10, 2, 35, 234000, tzinfo=tzutc()) > (datetime.datetime(2025, 7, 27, 22, 16, 38, 844421, tzinfo=tzutc()) - datetime.timedelta(days=1))
E + where datetime.datetime(2025, 7, 27, 22, 16, 38, 844421, tzinfo=tzutc()) =
E + where
E + and tzutc() = datetime.datetime(2025, 7, 25, 10, 2, 35, 234000, tzinfo=tzutc()).tzinfo
E + and datetime.timedelta(days=1) = timedelta(hours=24)
tests/ingestor/ingestor_test.py:57: AssertionError