-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
30 additions
and
30 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
File renamed without changes.
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
File renamed without changes.
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 |
---|---|---|
|
@@ -9,7 +9,7 @@ | |
import pytest | ||
import scipp as sc | ||
|
||
from scippneutron import __version__, meta | ||
from scippneutron import __version__, metadata | ||
from scippneutron.io import cif | ||
|
||
|
||
|
@@ -904,7 +904,7 @@ def test_builder_writes_audit_with_multiple_reducers() -> None: | |
def test_builder_with_beamline() -> None: | ||
original = cif.CIF() | ||
cif_ = original.with_beamline( | ||
meta.Beamline(name='DREAM', facility='ESS'), | ||
metadata.Beamline(name='DREAM', facility='ESS'), | ||
comment="Dreaming of things to come", | ||
) | ||
res = save_to_str(cif_) | ||
|
@@ -923,12 +923,12 @@ def test_builder_with_beamline() -> None: | |
def test_builder_with_beamline_and_source() -> None: | ||
original = cif.CIF() | ||
cif_ = original.with_beamline( | ||
meta.Beamline(name='Balder', facility='MAX IV'), | ||
meta.Source( | ||
frequency=meta.SourceFrequency(sc.scalar(0)), | ||
pulse_duration=meta.PulseDuration(sc.scalar(0)), | ||
source_type=meta.SourceType.SynchrotronXraySource, | ||
probe=meta.RadiationProbe.Xray, | ||
metadata.Beamline(name='Balder', facility='MAX IV'), | ||
metadata.Source( | ||
frequency=metadata.SourceFrequency(sc.scalar(0)), | ||
pulse_duration=metadata.PulseDuration(sc.scalar(0)), | ||
source_type=metadata.SourceType.SynchrotronXraySource, | ||
probe=metadata.RadiationProbe.Xray, | ||
), | ||
) | ||
res = save_to_str(cif_) | ||
|
@@ -1072,7 +1072,7 @@ def test_builder_powder_calibration(): | |
|
||
|
||
def test_builder_single_contact_author() -> None: | ||
author = meta.Person( | ||
author = metadata.Person( | ||
name='Jane Doe', | ||
email='[email protected]', | ||
address='Partikelgatan, Lund', | ||
|
@@ -1089,7 +1089,7 @@ def test_builder_single_contact_author() -> None: | |
|
||
|
||
def test_builder_regular_author() -> None: | ||
author = meta.Person( | ||
author = metadata.Person( | ||
name='Jane Doe', | ||
email='[email protected]', | ||
address='Partikelgatan, Lund', | ||
|
@@ -1107,14 +1107,14 @@ def test_builder_regular_author() -> None: | |
|
||
def test_builder_multiple_regular_authors() -> None: | ||
authors = [ | ||
meta.Person( | ||
metadata.Person( | ||
name='Jane Doe', | ||
email='[email protected]', | ||
address='Partikelgatan, Lund', | ||
orcid='https://orcid.org/0000-0000-0000-0001', | ||
corresponding=False, | ||
), | ||
meta.Person( | ||
metadata.Person( | ||
name='Max Mustermann', | ||
email='[email protected]', | ||
orcid='https://orcid.org/0000-0000-0001-0082', | ||
|
@@ -1135,7 +1135,7 @@ def test_builder_multiple_regular_authors() -> None: | |
|
||
|
||
def test_builder_regular_author_role() -> None: | ||
author = meta.Person( | ||
author = metadata.Person( | ||
name='Jane Doe', | ||
role='measurement', | ||
corresponding=False, | ||
|
@@ -1160,9 +1160,9 @@ def test_builder_regular_author_role() -> None: | |
def test_builder_many_fields() -> None: | ||
cif_ = ( | ||
cif.CIF('my/name') | ||
.with_authors(meta.Person(name='Jane Doe')) | ||
.with_authors(metadata.Person(name='Jane Doe')) | ||
.with_reducers('test-package') | ||
.with_beamline(beamline=meta.Beamline(name='fake')) | ||
.with_beamline(beamline=metadata.Beamline(name='fake')) | ||
) | ||
result = save_to_str(cif_) | ||
|
||
|
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