Gradle Test Run :test

CliArgsTest

summary

54

tests

0

failures

0

skipped

0.201s

duration

100%

successful

Child Name Tests Failures Skipped Duration Success rate
-ai-api-key sk-xxx sets aiOptions.apiKey=sk-xxx parse_aiApiKey_setsApiKey() 1 0 0 0.001s 100%
-ai-api-key-env MY_KEY sets aiOptions.apiKeyEnv=MY_KEY parse_aiApiKeyEnv_setsApiKeyEnv() 1 0 0 0s 100%
-ai-base-url http://custom sets aiOptions.baseUrl=http://custom parse_aiBaseUrl_setsBaseUrl() 1 0 0 0.001s 100%
-ai-confidence flag sets aiOptions.confidence=true parse_aiConfidenceFlag_setsConfidence() 1 0 0 0.003s 100%
-ai flag sets aiOptions.enabled=true parse_aiFlag_setsEnabled() 1 0 0 0s 100%
-ai-max-class-chars 50000 sets aiOptions.maxClassChars=50000 parse_aiMaxClassChars_setsValue() 1 0 0 0.001s 100%
-ai-max-retries 3 sets aiOptions.maxRetries=3 parse_aiMaxRetries_setsMaxRetries() 1 0 0 0s 100%
-ai-model gpt-4o-mini sets aiOptions.modelName=gpt-4o-mini parse_aiModel_setsModelName() 1 0 0 0.001s 100%
-ai-model with no following argument throws IllegalArgumentException mentioning the flag parse_aiModelMissingValue_throwsIllegalArgumentException() 1 0 0 0.001s 100%
-ai-provider ANTHROPIC (uppercase) sets aiOptions.provider=ANTHROPIC parse_aiProviderAnthropicUppercase_setsProvider() 1 0 0 0s 100%
-ai-provider openai sets aiOptions.provider=OPENAI parse_aiProviderOpenai_setsProvider() 1 0 0 0s 100%
-ai-taxonomy-mode optimized sets aiOptions.taxonomyMode=OPTIMIZED parse_aiTaxonomyMode_setsOptimized() 1 0 0 0.001s 100%
-ai-timeout-sec 30 sets aiOptions.timeout=Duration.ofSeconds(30) parse_aiTimeoutSec_setsTimeout() 1 0 0 0.002s 100%
-apply-tags flag sets applyTags=true parse_applyTagsFlag_setsApplyTagsTrue() 1 0 0 0.001s 100%
CLI -include-non-security overrides YAML outputMode sarif implicit filter parse_cliIncludeNonSecurityOverridesYamlSarifImplicit(Path) 1 0 0 0.008s 100%
CLI -override-file overrides YAML overrideFile value parse_cliOverrideFileOverridesYaml(Path) 1 0 0 0.009s 100%
-config with non-existent file throws IllegalArgumentException parse_configNonExistentFile_throwsIllegalArgumentException(Path) 1 0 0 0.003s 100%
-config with ai.enabled=false and ai.confidence=false leaves those flags unset parse_configWithAiEnabledFalseAndConfidenceFalse_doesNotActivate(Path) 1 0 0 0.006s 100%
-config with full ai section applies all twelve AI option fields parse_configWithFullAiSection_appliesAllTwelveAiFields(Path) 1 0 0 0.017s 100%
overrideFile from YAML config is applied as default parse_configWithOverrideFile_setsPath(Path) 1 0 0 0.010s 100%
securityOnly from YAML config is applied as default parse_configWithSecurityOnlyTrue_setsFlag(Path) 1 0 0 0.009s 100%
-config with valid YAML file applies YAML values (outputMode sarif, contentHash true) parse_configWithValidYaml_appliesYamlValues(Path) 1 0 0 0.008s 100%
-content-hash flag sets contentHash=true parse_contentHashFlag_setsContentHashTrue() 1 0 0 0.001s 100%
-emit-metadata flag sets emitMetadata=true parse_emitMetadataFlag_setsEmitMetadataTrue() 1 0 0 0.002s 100%
-emit-source-root flag sets emitSourceRoot=true parse_emitSourceRootFlag_setsTrue() 1 0 0 0.001s 100%
-file-suffix IT.java replaces default suffix parse_fileSuffix_replacesDefault() 1 0 0 0.001s 100%
-file-suffix with no following argument throws IllegalArgumentException mentioning the flag parse_fileSuffixMissingValue_throwsIllegalArgumentException() 1 0 0 0.001s 100%
-include-non-security alone in CSV mode has no effect on securityOnly parse_includeNonSecurityAlone_doesNotAffectCsvSecurityOnly() 1 0 0 0s 100%
-manual-consume workDir responseDir creates ManualMode.Consume with correct paths parse_manualConsume_createsConsumeModeWithPaths() 1 0 0 0.003s 100%
-manual-prepare workDir responseDir creates ManualMode.Prepare with correct paths parse_manualPrepare_createsPrepareModeWithPaths() 1 0 0 0.002s 100%
-test-marker and -test-annotation can be mixed and accumulate together parse_markerAndAnnotationMixed_accumulate() 1 0 0 0.001s 100%
multiple -file-suffix flags collect all and replace default on first occurrence parse_multipleFileSuffixes_allCollected() 1 0 0 0s 100%
multiple positional arguments are all added to paths list parse_multiplePositionalArgs_allAddedToPaths() 1 0 0 0.001s 100%
parse with no arguments returns default CliConfig parse_noArgs_returnsDefaults() 1 0 0 0.001s 100%
emitSourceRoot defaults to false when flag is absent parse_noEmitSourceRoot_defaultsFalse() 1 0 0 0.002s 100%
no -property flags produces an empty properties map parse_noProperty_emptyMap() 1 0 0 0.009s 100%
-override-file /tmp/overrides.yaml sets overrideFile path parse_overrideFileFlag_setsPath() 1 0 0 0.001s 100%
-plain flag sets PLAIN output mode parse_plainFlag_setsPlainMode() 1 0 0 0.002s 100%
positional non-flag argument is added to paths list parse_positionalArg_addedToPaths() 1 0 0 0.002s 100%
-property value missing '=' throws IllegalArgumentException parse_propertyMissingEquals_throwsException() 1 0 0 0.001s 100%
-sarif flag implies securityOnly=true without any explicit filter flag parse_sarifFlag_impliesSecurityOnly() 1 0 0 0.001s 100%
-sarif flag sets SARIF output mode parse_sarifFlag_setSarifMode() 1 0 0 0.001s 100%
-sarif with -include-non-security disables the implicit security-only filter parse_sarifWithIncludeNonSecurity_disablesImplicitFilter() 1 0 0 0.002s 100%
-security-only flag sets securityOnly=true in CSV mode parse_securityOnlyFlag_setsTrue() 1 0 0 0.001s 100%
-property key=value stores single value under key parse_singleProperty_stored() 1 0 0 0.001s 100%
-test-annotation is accepted as a backward-compatible alias for -test-marker parse_testAnnotationAlias_sameAsTestMarker() 1 0 0 0.001s 100%
-test-marker MyTest replaces defaults with {MyTest} parse_testMarker_replacesDefaults() 1 0 0 0.001s 100%
two -property flags with different keys are both stored parse_twoPropertiesDifferentKeys_bothStored() 1 0 0 0.001s 100%
two -property flags with the same key accumulate into a list parse_twoPropertiesSameKey_accumulate() 1 0 0 0.002s 100%
two -test-marker flags accumulate both values parse_twoTestMarkers_bothPresent() 1 0 0 0.003s 100%
unknown -ai-unknown flag throws IllegalArgumentException parse_unknownAiFlag_throwsIllegalArgumentException() 1 0 0 0s 100%
unknown -xyz flag throws IllegalArgumentException parse_unknownFlag_throwsIllegalArgumentException() 1 0 0 0.007s 100%
YAML outputMode sarif implies securityOnly even without -security-only flag parse_yamlSarifMode_impliesSecurityOnly(Path) 1 0 0 0.009s 100%
YAML outputMode sarif with includeNonSecurity true disables implicit filter parse_yamlSarifModeWithIncludeNonSecurity_disablesFilter(Path) 1 0 0 0.007s 100%