Skip to content

Use $COMP_ROOT_DIR_LND in place of $SRCROOT for FATES testmods -- so can work in CESM or CAM checkouts #3580

Description

@ekluzek

In several FATES testmods we use $SRCROOT to get the top level path of the CLM src directory. However, we should use COMP_ROOT_DIR_LND instead since $SRCROOT will be incorrect when working in a CESM or CAM checkout.

git grep SRCROOT shows the following files that should change...

cime_config/testdefs/testmods_dirs/clm/FatesColdPRT2/shell_commands:SRCDIR=`./xmlquery SRCROOT --value`
cime_config/testdefs/testmods_dirs/clm/FatesColdSeedDisp/README:file generated on the fly is placed in the $SRCROOT/src/fates/parameter_files
cime_config/testdefs/testmods_dirs/clm/FatesColdSeedDisp/README:directory.  This may still run into problems is the $SRCROOT string is too long.
cime_config/testdefs/testmods_dirs/clm/FatesColdSeedDisp/shell_commands:SRCDIR=`./xmlquery SRCROOT --value`
cime_config/testdefs/testmods_dirs/clm/FatesColdTwoStream/README:file generated on the fly is placed in the $SRCROOT/src/fates/parameter_files
cime_config/testdefs/testmods_dirs/clm/FatesColdTwoStream/README:directory.  This may still run into problems is the $SRCROOT string is too long.
cime_config/testdefs/testmods_dirs/clm/FatesSetupParamBuild/shell_commands:      SRCDIR=$(./xmlquery SRCROOT --value || echo "null")
cime_config/testdefs/testmods_dirs/clm/FatesSetupParamBuild/shell_commands:      check_error $? "Trouble getting SRCROOT from case"

Metadata

Metadata

Assignees

No one assigned

    Labels

    b4bbit-for-bitcode healthimproving internal code structure to make easier to maintain (sustainability)enhancementnew capability or improved behavior of existing capabilitypriority: lowBackground task that doesn't need to be done right away.size: smalltestingadditions or changes to testsusabilityImprove or clarify user-facing options

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions