Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
nomad-FAIR
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
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
Service Desk
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
nomad-lab
nomad-FAIR
Merge requests
!1990
Minor doc update for py311
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Minor doc update for py311
minor-doc-fix
into
develop
Overview
0
Commits
1
Pipelines
3
Changes
2
Merged
Ahmed Ilyas
requested to merge
minor-doc-fix
into
develop
8 months ago
Overview
0
Commits
1
Pipelines
3
Changes
1
Expand
0
0
Merge request reports
Compare
version 1
version 1
35205718
8 months ago
develop (base)
and
latest version
latest version
d94e1bbc
1 commit,
8 months ago
version 1
35205718
1 commit,
8 months ago
Show latest version
1 file
+
0
−
28
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
tests/datamodel/metainfo/eln/test_system.py
+
0
−
28
Options
@@ -24,34 +24,6 @@ from nomad.utils.exampledata import ExampleData
from
tests.normalizing.conftest
import
run_normalize
def
test_substance
(
raw_files_function
,
user1
,
mongo_function
):
directory
=
'
tests/data/datamodel/metainfo/eln
'
mainfile
=
'
test_substance.archive.yaml
'
upload_id
=
'
test_upload_id
'
data
=
ExampleData
(
main_author
=
user1
)
data
.
create_upload
(
upload_id
=
upload_id
,
published
=
False
)
context
=
ClientContext
(
local_dir
=
directory
,
upload_id
=
upload_id
)
test_archive
=
data
.
create_entry_from_file
(
upload_id
=
upload_id
,
mainfile
=
os
.
path
.
join
(
directory
,
mainfile
),
entry_archive
=
EntryArchive
(
m_context
=
context
),
)
data
.
save
(
with_es
=
False
)
# Check that entry type is the custom 'my_substance' class
assert
test_archive
.
metadata
.
entry_type
==
'
my_substance
'
# Check that api call to CAS found Lead Iodide
assert
test_archive
.
data
.
cas_number
==
'
10101-63-0
'
# Check that the material results section was populated by the normalizer
assert
'
I
'
in
test_archive
.
results
.
material
.
elements
assert
'
Pb
'
in
test_archive
.
results
.
material
.
elements
os
.
unlink
(
os
.
path
.
join
(
directory
,
'
cas_10101-63-0_image.svg
'
))
def
test_ensemble
(
raw_files_function
,
user1
,
mongo_function
):
directory
=
'
tests/data/datamodel/metainfo/eln
'
mainfile
=
'
test_ensemble.archive.yaml
'
Loading