Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test Components #85

Open
1 of 7 tasks
rburghol opened this issue Jan 30, 2024 · 0 comments
Open
1 of 7 tasks

Test Components #85

rburghol opened this issue Jan 30, 2024 · 0 comments

Comments

@rburghol
Copy link

rburghol commented Jan 30, 2024

Create a set of scripts to:

  • test all functionality in model
  • test parser performance
  • provide basic cases for unit test validation (to insure that changes haven't broken anything obvious)
  • consider multiple separate sets?
  • consider a performance testing ensemble of components?
  • test cases should all be JSON?
    • for starters yes, though there might be an argument for programmatic tester (though it would be more complicated)

Tasks:

{
    "RCHRES_R001": {
        "name": "RCHRES_R001",
        "object_class": "ModelObject",
        "local_area_sqmi": {
            "name": "local_area_sqmi",
            "object_class": "Constant",
            "value": 6.155817237
        },
        "read_from_children": {
            "name": "read_from_children",
            "object_class": "ModelBroadcast",
            "broadcast_type": "read",
            "broadcast_channel": "hydroObject",
            "broadcast_hub": "self",
            "broadcast_params": [
                [
                    "Qtrib",
                    "Qtrib"
                ],
                [
                    "trib_area_sqmi",
                    "trib_area_sqmi"
                ],
                [
                    "child_wd_mgd",
                    "wd_mgd"
                ]
            ]
        },
        "Qlocal": {
            "name": "Qlocal",
            "object_class": "Equation",
            "value": "local_area_sqmi * Runit"
        },
        "Qin": {
            "name": "Qin",
            "object_class": "Equation",
            "equation": "Qlocal + Qtrib"
        },
        "Qout": {
            "name": "Qout",
            "object_class": "Equation",
            "equation": "Qin * 1.0"
        },
        "drainage_area_sqmi": {
            "name": "drainage_area_sqmi",
            "object_class": "Equation",
            "equation": "local_area_sqmi + trib_area_sqmi"
        },
        "IVOLin": {
            "name": "IVOLin",
            "object_class": "ModelLinkage",
            "right_path": "/STATE/RCHRES_R001/HYDR/IVOL",
            "link_type": 2
        },
        "IVOL": {
            "name": "IVOL",
            "object_class": "ModelLinkage",
            "right_path": "/STATE/RCHRES_R001/Qin"
        },
        "Runit": {
            "name": "Runit",
            "object_class": "Equation",
            "value": "IVOLin / drainage_area_sqmi"
        }
    }
}



Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant