Skip to content

Commit

Permalink
Add Unit Test
Browse files Browse the repository at this point in the history
- update unit test for discrete frequency sweep in HFSS.
  • Loading branch information
Devin-Crawford committed Jan 30, 2025
1 parent 04f94ce commit 8677e2c
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions tests/system/general/test_11_Setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,11 @@ def test_01_create_hfss_setup(self):
max_delta_phase=8,
custom_entries=[["1", "2", 0.03, 4]],
)
setup2 = self.aedtapp.create_setup("MulitFreqSetup",
MultipleAdaptiveFreqsSetup=["1GHz", "2GHz"],
MaximumPasses=3)
assert setup2.props["SolveType"] == "MultiFrequency"
assert setup2.props["MaximumPasses"] == 3

def test_01b_create_hfss_sweep(self):
self.aedtapp.save_project()
Expand All @@ -121,6 +126,15 @@ def test_01b_create_hfss_sweep(self):
assert sweep3.props["Type"] == "Discrete"
sweep4 = setup1.create_frequency_sweep("GHz", 23, 25, 401, sweep_type="Fast")
assert sweep4.props["Type"] == "Fast"
range_start = "1GHz"
range_end = "2GHz"
range_step = "0.5GHz"
sweep5 = setup1.add_sweep("DiscSweep5", sweep_type="Discrete", RangeStart=range_start,
RangeEnd=range_end, RangeStep=range_step, SaveFields=True)
assert sweep5.props["Type"] == "Discrete"
assert sweep5.props["RangeStart"] == range_start
assert sweep5.props["RangeEnd"] == range_end
assert sweep5.props["RangeStep"] == range_step

def test_01c_create_hfss_setup_auto_open(self):
self.aedtapp.duplicate_design("auto_open")
Expand Down

0 comments on commit 8677e2c

Please sign in to comment.