Skip to content

Commit 9851010

Browse files
committed
mend
1 parent 5b2e091 commit 9851010

File tree

4 files changed

+58
-0
lines changed

4 files changed

+58
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
[General]
2+
BASENAME = converter/svo
3+
4+
[Group 1]
5+
SHELLS = 1
6+
NORMALIZE = True
7+
EWINDOW = -1.4 2.0
8+
9+
[Shell 1]
10+
LSHELL = 2
11+
IONS = 2
12+
13+
TRANSFORM = 1.0 0.0 0.0 0.0 0.0
14+
0.0 1.0 0.0 0.0 0.0
15+
0.0 0.0 0.0 1.0 0.0
16+
101 KB
Binary file not shown.
1.49 MB
Binary file not shown.
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
2+
import os
3+
import rpath
4+
_rpath = os.path.dirname(rpath.__file__) + '/'
5+
6+
from triqs_dft_tools.converters.plovasp.converter import generate_and_output_as_text
7+
from triqs_dft_tools.converters import VaspConverter
8+
import mytest
9+
10+
################################################################################
11+
#
12+
# TestConverterOneSite
13+
#
14+
################################################################################
15+
class TestConverterSVO(mytest.MyTestCase):
16+
"""
17+
Function:
18+
19+
def generate_and_output_as_text(pars, el_struct)
20+
and
21+
VaspConverter
22+
23+
Scenarios:
24+
25+
- Parse config file and produce a correct converted h5-file
26+
"""
27+
# Scenario 1
28+
def test_convert_svo(self):
29+
generate_and_output_as_text(_rpath + 'svo.cfg', _rpath + 'svo/')
30+
31+
test_file = _rpath + 'svo.test.h5'
32+
converter = VaspConverter(filename=_rpath + 'svo',
33+
hdf_filename=test_file)
34+
35+
converter.convert_dft_input()
36+
37+
expected_file = _rpath + 'svo.ref.h5'
38+
self.assertH5FileEqual(test_file, expected_file)
39+
40+
if __name__ == '__main__':
41+
import unittest
42+
unittest.main(verbosity=2, buffer=False)

0 commit comments

Comments
 (0)