From 028ac8fcef8a1d582c077f9cbffc538a8caf2048 Mon Sep 17 00:00:00 2001 From: Keisuke Yanagisawa Date: Fri, 16 Aug 2024 02:26:55 +0000 Subject: [PATCH] update unittest codes --- script/test_generate_msmd_system.py | 10 +++++++--- script/utilities/test_parse_setting_yaml.py | 3 ++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/script/test_generate_msmd_system.py b/script/test_generate_msmd_system.py index 6cdc3b5..d306f1d 100644 --- a/script/test_generate_msmd_system.py +++ b/script/test_generate_msmd_system.py @@ -2,8 +2,12 @@ from typing import Literal from unittest import TestCase -from script.generate_msmd_system import _create_frcmod, calculate_boxsize, generate_msmd_system -from script.utilities import util +from script.generate_msmd_system import ( + _create_frcmod, + calculate_boxsize, + generate_msmd_system, +) +from script.setting import parse_yaml class TestBoxSizeCalculation(TestCase): @@ -32,7 +36,7 @@ def __init__(self, *args, **kwargs): self.expected_rst7_file = __testdata_dir / "tripeptide_A11.rst7" def test_generate_msmd_system(self): - settings = util.parse_yaml(self.setting_file) + settings = parse_yaml(self.setting_file) parm7, rst7 = generate_msmd_system(settings, seed=1) # first line contains the date and time, so we skip it for comparison diff --git a/script/utilities/test_parse_setting_yaml.py b/script/utilities/test_parse_setting_yaml.py index ff121d6..a83dd83 100644 --- a/script/utilities/test_parse_setting_yaml.py +++ b/script/utilities/test_parse_setting_yaml.py @@ -1,7 +1,8 @@ from pathlib import Path from unittest import TestCase -from script.utilities.util import expand_index, parse_yaml +from script.setting import parse_yaml +from script.utilities.util import expand_index class TestParseNormalSettingYaml(TestCase):