Documentation ¶
Overview ¶
Given old and new step gives the filenames of specification, concepts and files in code changed. Refactoring Flow: - Refactor specs and concepts in memory - Checks if it is a concept or not - In case of concept - writes to file and skips the runner - If its not a concept (its a step) - need to know the text, so makes a call to runner to get the text(step name) - Refactors the text(changes param positions ect) and sends it to runner to refactor implementations.
Index ¶
- func GetRefactoringChanges(oldStep, newStep string, runner runner.Runner, specDirs []string) *refactoringResult
- func PerformRephraseRefactoring(oldStep, newStep string, startChan *runner.StartChannels, specDirs []string) *refactoringResult
- func RefactorSteps(oldStep, newStep string, startChan *runner.StartChannels, specDirs []string)
- func SliceIndex(limit int, predicate func(i int) bool) int
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetRefactoringChanges ¶ added in v0.9.8
func GetRefactoringChanges(oldStep, newStep string, runner runner.Runner, specDirs []string) *refactoringResult
GetRefactoringChanges given an old step and new step gives the list of steps that need to be changed to perform refactoring. It also provides the changes to be made on the implementation files.
func PerformRephraseRefactoring ¶
func PerformRephraseRefactoring(oldStep, newStep string, startChan *runner.StartChannels, specDirs []string) *refactoringResult
PerformRephraseRefactoring given an old step and new step refactors specs and concepts in memory and if its a concept writes to file else invokes runner to get the step name and refactors the step and sends it to runner to refactor implementation.
func RefactorSteps ¶
func RefactorSteps(oldStep, newStep string, startChan *runner.StartChannels, specDirs []string)
RefactorSteps performs rephrase refactoring and prints the refactoring summary which includes errors and warnings generated during refactoring and files changed during refactoring : specification files, concept files and the implementation files changed.
Types ¶
This section is empty.