Beispiel #1
0
def test_loaderror():
    """Test raising LoadError."""
    with pytest.raises(LoadError):
        core.TrackRun(str(TEST_DIR))
    with pytest.raises(LoadError):
        tr = core.TrackRun()
        tr.load_data(TEST_DIR / "nonexistent_dir")
Beispiel #2
0
def test_load_data():
    """Create an empty TrackRun instance and load data afterwards."""
    tr = core.TrackRun()
    tr.load_data(TEST_DIR)
    assert len(tr) == 76
    assert tr.size() == 76
    assert not tr.is_categorised
Beispiel #3
0
def trackrun():
    """Load and cache data."""
    return core.TrackRun(TEST_DIR)