forked from cleveragents/cleveragents-core
41 lines
1.5 KiB
Gherkin
41 lines
1.5 KiB
Gherkin
@discovery
|
|
Feature: Discovery Module Functions
|
|
As a developer
|
|
I want to test the discovery module functionality
|
|
So that I have confidence in the extraction tools
|
|
|
|
Scenario: Import discovery module
|
|
When I import the discovery module
|
|
Then it should have CLIInventoryExtractor available
|
|
|
|
Scenario: Run discovery main script
|
|
When I run the discovery CLI inventory main
|
|
Then it should extract and save the inventory
|
|
|
|
Scenario: Parse Go variable names to command names
|
|
Given a CLI inventory extractor instance
|
|
When I convert "applyCmd" to command name
|
|
Then the converted name should be "apply"
|
|
When I convert "deleteIplanCmd" to command name
|
|
Then the converted name should be "delete-iplan"
|
|
When I convert "setModelCmd" to command name
|
|
Then the converted name should be "set-model"
|
|
|
|
Scenario: Build command hierarchy
|
|
Given a CLI inventory extractor instance
|
|
When I build the command hierarchy
|
|
Then it should return a hierarchical structure
|
|
|
|
Scenario: Gather statistics
|
|
Given a CLI inventory extractor instance
|
|
When I gather statistics about extracted commands
|
|
Then statistics should include total_commands
|
|
And statistics should include commands_with_aliases
|
|
And statistics should include commands_with_flags
|
|
|
|
Scenario: Extract additional metadata
|
|
Given a CLI inventory extractor instance
|
|
When I extract additional metadata
|
|
Then metadata should include repl_commands
|
|
And metadata should include shortcuts
|
|
And metadata should include environment_variables |