Skip to content

Commit

Permalink
fix doctests
Browse files Browse the repository at this point in the history
  • Loading branch information
InnocentBug committed Mar 8, 2024
1 parent 5dd63e6 commit 80d56e4
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions src/cript/nodes/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,10 +293,10 @@ def get_expanded_json(self, **kwargs) -> str:
>>> my_project = cript.Project(name=f"my_Project")
>>> my_collection = cript.Collection(name="my collection")
>>> my_material_1 = cript.Material(
... name="my material 1", bigsmiles = "my material 1 bigsmiles"]
... name="my material 1", bigsmiles = "my material 1 bigsmiles"
... )
>>> my_material_2 = cript.Material(
... name="my material 2", bigsmiles = "my material 2 bigsmiles"]
... name="my material 2", bigsmiles = "my material 2 bigsmiles"
... )
>>> my_inventory = cript.Inventory(
... name="my inventory", material=[my_material_1, my_material_2]
Expand Down Expand Up @@ -511,10 +511,10 @@ def find_children(self, search_attr: dict, search_depth: int = -1, handled_nodes
>>> my_project = cript.Project(name=f"my_Project")
>>> my_collection = cript.Collection(name="my collection")
>>> my_material_1 = cript.Material(
... name="my material 1", bigsmiles = "my material 1 bigsmiles"]
... name="my material 1", bigsmiles = "my material 1 bigsmiles"
... )
>>> my_material_2 = cript.Material(
... name="my material 2", bigsmiles = "my material 2 bigsmiles"]
... name="my material 2", bigsmiles = "my material 2 bigsmiles"
... )
>>> my_inventory = cript.Inventory(
... name="my inventory", material=[my_material_1, my_material_2]
Expand Down
2 changes: 1 addition & 1 deletion src/cript/nodes/primary_nodes/computation_process.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ def ingredient(self) -> List[Any]:
Examples
--------
>>> import cript
>>> my_material = cript.Material(name="my material", "bigsmiles" = "my bigsmiles")
>>> my_material = cript.Material(name="my material", bigsmiles = "my bigsmiles")
>>> my_quantity = cript.Quantity(
... key="mass", value=11.2, unit="kg", uncertainty=0.2, uncertainty_type="stdev"
... )
Expand Down
2 changes: 1 addition & 1 deletion src/cript/nodes/primary_nodes/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ def material(self) -> List[Any]:
... data_dictionary="my file's data dictionary"
... )
>>> my_data = cript.Data(name="my data name", type="afm_amp", file=[my_file])
>>> my_material = cript.Material(name="my material name", bigsmiles = 123456)
>>> my_material = cript.Material(name="my material name", bigsmiles = "123456")
>>> my_data.material = [my_material]
Returns
Expand Down
6 changes: 3 additions & 3 deletions src/cript/nodes/primary_nodes/material.py
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,7 @@ def component(self) -> List["Material"]:
>>> my_mixed_material = cript.Material(
... name="my material",
... component=my_components,
... "bigsmiles" = "123456",
... bigsmiles = "123456",
... )
Returns
Expand Down Expand Up @@ -486,7 +486,7 @@ def keyword(self) -> List[str]:
--------
>>> import cript
>>> my_material = cript.Material(
... name="my material", "inchi" = "my material inchi"
... name="my material", inchi = "my material inchi"
... )
>>> my_material.keyword = ["acetylene", "acrylate", "alternating"]
Expand Down Expand Up @@ -536,7 +536,7 @@ def property(self) -> List[Any]:
>>> import cript
>>> my_material = cript.Material(
... name="my component material 1",
... "smiles" = "component 1 smiles",
... smiles = "component 1 smiles",
... )
>>> my_property = cript.Property(key="modulus_shear", type="min", value=1.23, unit="gram")
>>> my_material.property = [my_property]
Expand Down

0 comments on commit 80d56e4

Please sign in to comment.