Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PTR-MS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
EBAS-DATA-PROCESSING
CiGas-processing-software
PTR-MS
Commits
00160a61
Commit
00160a61
authored
5 months ago
by
Marc-Antoine Drouin
Browse files
Options
Downloads
Patches
Plain Diff
chore: apply updated formatting of ruff
parent
341a596d
No related branches found
No related tags found
No related merge requests found
Pipeline
#2133
passed
5 months ago
Stage: quality
Stage: test
Changes
3
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
tests/ames/test_ames.py
+1
-1
1 addition, 1 deletion
tests/ames/test_ames.py
tests/conftest.py
+4
-4
4 additions, 4 deletions
tests/conftest.py
tests/sirta/conftest.py
+10
-10
10 additions, 10 deletions
tests/sirta/conftest.py
with
15 additions
and
15 deletions
tests/ames/test_ames.py
+
1
−
1
View file @
00160a61
...
...
@@ -3,7 +3,7 @@ import pytest
from
cigas_ptrms.readers.ames
import
Ames1001
,
AmesVariableMeta
@pytest.fixture
()
@pytest.fixture
def
lev0_file
(
lev0_dir
):
"""
Return lev0 file.
"""
return
lev0_dir
/
"
ref_lev0.nas
"
...
...
This diff is collapsed.
Click to expand it.
tests/conftest.py
+
4
−
4
View file @
00160a61
...
...
@@ -5,25 +5,25 @@ from pathlib import Path
import
pytest
@pytest.fixture
()
@pytest.fixture
def
root_dir
(
request
)
->
Path
:
# type: ignore
"""
Return root directory of tests.
"""
return
Path
(
request
.
config
.
rootdir
/
"
tests
"
)
@pytest.fixture
()
@pytest.fixture
def
data_dir
(
root_dir
:
Path
)
->
Path
:
"""
Return data directory of tests.
"""
return
root_dir
/
"
data
"
@pytest.fixture
()
@pytest.fixture
def
lev0_dir
(
data_dir
:
Path
)
->
Path
:
"""
Return lev0 directory of tests.
"""
return
data_dir
/
"
lev0
"
@pytest.fixture
()
@pytest.fixture
def
sirta_dir
(
data_dir
:
Path
)
->
Path
:
"""
Return sirta directory of tests.
"""
return
data_dir
/
"
sirta
"
This diff is collapsed.
Click to expand it.
tests/sirta/conftest.py
+
10
−
10
View file @
00160a61
...
...
@@ -3,19 +3,19 @@ from zipfile import ZipFile
import
pytest
@pytest.fixture
()
@pytest.fixture
def
zip_raw_1_file
(
sirta_dir
):
"""
Return a zip file.
"""
return
sirta_dir
/
"
ptrms_0a_Lz5L705F5minUptcUptr_v01_20240730_001608_528.zip
"
@pytest.fixture
()
@pytest.fixture
def
zip_raw_n_files
(
sirta_dir
):
"""
Return zip files.
"""
return
sorted
(
sirta_dir
.
glob
(
"
ptrms_0a_Lz5L705F5minUptcUptr_v01_2024072*.zip
"
))
@pytest.fixture
()
@pytest.fixture
def
unzip_dir_1_file
(
tmp_path
,
zip_raw_1_file
):
"""
Return a directory to unzip files.
"""
path
=
tmp_path
/
"
unzip_1
"
...
...
@@ -28,7 +28,7 @@ def unzip_dir_1_file(tmp_path, zip_raw_1_file):
return
path
@pytest.fixture
()
@pytest.fixture
def
unzip_dir_n_files
(
tmp_path
,
zip_raw_n_files
):
"""
Return a directory to unzip files.
"""
path
=
tmp_path
/
"
unzip_n
"
...
...
@@ -42,37 +42,37 @@ def unzip_dir_n_files(tmp_path, zip_raw_n_files):
return
path
@pytest.fixture
()
@pytest.fixture
def
ptr_1_file
(
unzip_dir_1_file
):
"""
Return a ptr file.
"""
return
sorted
(
unzip_dir_1_file
.
glob
(
"
*.ptr
"
))
@pytest.fixture
()
@pytest.fixture
def
ptc_1_file
(
unzip_dir_1_file
):
"""
Return a ptc file.
"""
return
sorted
(
unzip_dir_1_file
.
glob
(
"
*.ptc
"
))
@pytest.fixture
()
@pytest.fixture
def
valve_1_file
(
unzip_dir_1_file
):
"""
Return a valve file.
"""
return
sorted
(
unzip_dir_1_file
.
glob
(
"
*.csv
"
))
@pytest.fixture
()
@pytest.fixture
def
ptr_n_files
(
unzip_dir_n_files
):
"""
Return a ptr file.
"""
return
sorted
(
unzip_dir_n_files
.
glob
(
"
*.ptr
"
))
@pytest.fixture
()
@pytest.fixture
def
ptc_n_files
(
unzip_dir_n_files
):
"""
Return a ptc file.
"""
return
sorted
(
unzip_dir_n_files
.
glob
(
"
*.ptc
"
))
@pytest.fixture
()
@pytest.fixture
def
valve_n_files
(
unzip_dir_n_files
):
"""
Return a valve file.
"""
return
sorted
(
unzip_dir_n_files
.
glob
(
"
*.csv
"
))
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment