Skip to content

Commit

Permalink
TestRunner CLI defaults are current TRAPI and Biolink releases, not None
Browse files Browse the repository at this point in the history
  • Loading branch information
RichardBruskiewich committed May 16, 2024
1 parent b5c2735 commit ac4ec00
Show file tree
Hide file tree
Showing 3 changed files with 141 additions and 116 deletions.
16 changes: 12 additions & 4 deletions graph_validation_tests/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

from argparse import ArgumentParser

from reasoner_validator.versioning import get_latest_version
from reasoner_validator.biolink import BiolinkValidator
from reasoner_validator.validator import TRAPIResponseValidator
from reasoner_validator.message import MESSAGES_BY_TARGET, MESSAGE_CATALOG, MESSAGES_BY_TEST
Expand All @@ -17,9 +18,15 @@
from graph_validation_tests.translator.trapi import get_available_components
from graph_validation_tests.utils.asyncio import gather

from bmt import Toolkit

import logging
logger = logging.getLogger(__name__)

# as long as TRAPI has major version == "1", we should be OK here
default_trapi_release: str = get_latest_version("1")
default_biolink_model_version: str = Toolkit().get_model_version()


class TestCaseRun(TRAPIResponseValidator):
"""
Expand Down Expand Up @@ -676,16 +683,17 @@ def get_parameters(tool_name: str):
parser.add_argument(
"--trapi_version",
type=str,
help="TRAPI version expected for knowledge graph access (Default: use latest TRAPI community release)",
default=None
help="TRAPI version expected for knowledge graph access" +
f" (Default: use latest TRAPI community release: '{default_trapi_release}')",
default=default_trapi_release
)

parser.add_argument(
"--biolink_version",
type=str,
help="Biolink Model version expected for knowledge graph access " +
"(Default: use current default release of the Biolink Model Toolkit)",
default=None
f"(Default: use current default release of the Biolink Model Toolkit: '{default_biolink_model_version}')",
default=default_biolink_model_version
)

parser.add_argument(
Expand Down
Loading

0 comments on commit ac4ec00

Please sign in to comment.