コード例 #1
0
ファイル: test_rest.py プロジェクト: adozier/pymatgen
 def test_find_structure(self):
     # nosetests pymatgen/matproj/tests/test_rest.py:MPResterTest.test_find_structure
     m = MPRester()
     ciffile = os.path.join(test_dir, 'Fe3O4.cif')
     data = m.find_structure(ciffile)
     self.assertTrue(len(data) > 1)
     s = CifParser(ciffile).get_structures()[0]
     data = m.find_structure(s)
     self.assertTrue(len(data) > 1)
コード例 #2
0
ファイル: test_rest.py プロジェクト: clairesaunders/pymatgen
 def test_find_structure(self):
     # nosetests pymatgen/matproj/tests/test_rest.py:MPResterTest.test_find_structure
     m = MPRester()
     ciffile = os.path.join(test_dir, 'Fe3O4.cif')
     data = m.find_structure(ciffile)
     self.assertTrue(len(data) > 1)
     s = CifParser(ciffile).get_structures()[0]
     data = m.find_structure(s)
     self.assertTrue(len(data) > 1)
コード例 #3
0
ファイル: test_rest.py プロジェクト: HiPeter/pymatgen
 def test_find_structure(self):
     # nosetests pymatgen/matproj/tests/test_rest.py:MPResterTest.test_find_structure
     # self.rester points to rest/v2 by default which doesn't have the find_structure endpoint
     m = MPRester(endpoint="https://www.materialsproject.org/rest")
     ciffile = os.path.join(test_dir, 'Fe3O4.cif')
     data = m.find_structure(ciffile)
     self.assertTrue(len(data) > 1)
     s = CifParser(ciffile).get_structures()[0]
     data = m.find_structure(s)
     self.assertTrue(len(data) > 1)
コード例 #4
0
ファイル: test_rest.py プロジェクト: yevgeniypuzyrev/pymatgen
 def test_find_structure(self):
     # nosetests pymatgen/matproj/tests/test_rest.py:MPResterTest.test_find_structure
     # self.rester points to rest/v2 by default which doesn't have the find_structure endpoint
     m = MPRester(endpoint="https://www.materialsproject.org/rest")
     ciffile = os.path.join(test_dir, 'Fe3O4.cif')
     data = m.find_structure(ciffile)
     self.assertTrue(len(data) > 1)
     s = CifParser(ciffile).get_structures()[0]
     data = m.find_structure(s)
     self.assertTrue(len(data) > 1)