-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #20 from hgloeckner/minor_l3_changes
Minor l3 changes
- Loading branch information
Showing
4 changed files
with
44 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import pytest | ||
import os | ||
import xarray as xr | ||
from pydropsonde.processor import Gridded | ||
|
||
sondes = None | ||
l3_default = f"Level_3.nc" | ||
|
||
|
||
@pytest.fixture | ||
def gridded(): | ||
return Gridded(sondes) | ||
|
||
|
||
def test_l3_dir(gridded): | ||
with pytest.raises(ValueError): | ||
gridded.get_l3_dir() | ||
|
||
|
||
def test_l3_dir_name(gridded): | ||
gridded.get_l3_dir(l3_dir="test") | ||
assert gridded.l3_dir == "test" | ||
|
||
|
||
def test_l3_default(gridded): | ||
gridded.get_l3_filename() | ||
assert gridded.l3_filename == l3_default |