Repository navigation
test(ui): expand automated unit test coverage across all DockWidget modules to 91% - #151
Merged
Merged
Conversation
…Column dock widgets
… and flowsheet result updates
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR significantly expands unit test coverage across all DockWidget modules (
src/main/python/DockWidgets/), lifting the module coverage from the baseline ~61% to 91%, witall 541 automated tests passing cleanly across the repository.
Upstream changes from
master(including PRs #145, #146, #147, #148, #150) have also been merged cleanly with zero regressions.Coverage Improvements by Module
DistillationColumnStagewiseResults.pyDockWidgetDistillationColumn.pyDockWidgetMaterialStream.pyDockWidgetSplitter.pyDockWidgetCompoundSeparator.pyDockWidgetFlash.pyDockWidget.py(Base & Generic DockWidgets)DockWidgetShortcutColumn.pyDockWidgetCompressorExpander.pyDockWidgetMixer.pyDockWidgets/)Key Test Additions & Logic Covered
Splitter (
DockWidgetSplitter.py: 93%):on_output_count_changed) and dynamic field reconstruction.Split_Ratio,Molar_Flow,Mass_Flow).auto_distribute_from_inputandget_input_flowextraction from upstream connected material streams, including edge cases (no stream connected, negative flow).update_connected_component_names), dock autosizing (_autosize), and input validation (empty fields, negative values, sum mismatches).Distillation Column (
DockWidgetDistillationColumn.py: 95%):results_category(): populates the main properties table and stagewise tables (stage_res_table.T_tableandstage_res_table.x_pc_table).showStagewiseResults(),showResult(),clear_results(), and dynamic condenser/reboiler dropdown transitions (fun2(),fun3()).Material Stream (
DockWidgetMaterialStream.py: 93%):PT,PH,PVF,TVF,PS).Mole Fraction,Mass Fraction,Mole Flow,Mass Flow).equalize(),normalize(),update_compounds(), and full simulation results parsing into phase and vapor pressure tables.Compressor & Expander (
DockWidgetCompressorExpander.py: 88%):AdiabaticCompressorandAdiabaticExpanderacross all operation modes (Pdel,Pout,Q).Base DockWidget & Remaining Modules (
DockWidget.py: 90%, CompoundSeparator: 91%, ShortcutColumn: 89%, Mixer: 87%, Flash: 90%):BaseDockWidgetrenaming validation (duplicate names, invalid characters, empty strings), energy stream cascading (EngStms), flowsheetresult_dataupdates, and
get_node_item()canvas lookups.set_read_only()state propagation across all controls.CompoundSeparator,ShortcutColumn,Mixer, andFlash.