This implementation should provide an autocompletion list for TEST.SUBPROGRAM without using the fake TEST.VALUE line described in #170.
Explanation:
In order to get the autocompletion list for TEST.SUBPROGRAM, we need the <unit> from TEST.UNIT.
This is retrieved with getNearest() in tstCompletion.ts.
This <unit> is sent as an additional parameter to the Python logic.
In processSubprogramLines() (tstUtilities.py), we use this <unit> to retrieve, with getFunctions(), the autocompletion list of all the functions in this unit from the DataAPI.
At the end, we add SUBPROGRAM-specific autocompletions like <<INIT>>, <<COMPOUND>>, <<coded_tests_driver>>.
Basically, the implementation works. However, we need to answer some questions:
2) What about the SUBPROGRAM-specific autocompletions (<<INIT>>, <<COMPOUND>>, coded_tests_driver)?
Is it all right to add them like that in processSubprogramLines(), or should this also be retrieved from the DataAPI somehow?
Summary:
This implementation should provide an autocompletion list for
TEST.SUBPROGRAM
without using the fakeTEST.VALUE
line described in #170.Explanation:
TEST.SUBPROGRAM
, we need the<unit>
fromTEST.UNIT
.getNearest()
intstCompletion.ts
.<unit>
is sent as an additional parameter to the Python logic.processSubprogramLines()
(tstUtilities.py), we use this<unit>
to retrieve, withgetFunctions()
, theautocompletion
list of all the functions in this unit from theDataAPI
.<<INIT>>, <<COMPOUND>>, <<coded_tests_driver>>
.Basically, the implementation works. However, we need to answer some questions:
Questions:
1) Passing this argument into
getChoiceDataFromPython
is straightforward, but how about the "server-side" autocompletion retrieval ingetChoiceDataFromServer()
?https://github.com/vectorgrp/vector-vscode-vcast/blob/2992c9ea72a87dcbbf7e3626ea6fcb6e7b5a26b5/server/pythonUtilities.ts#L101
2) What about the SUBPROGRAM-specific autocompletions (
<<INIT>>, <<COMPOUND>>, coded_tests_driver
)?Is it all right to add them like that in
processSubprogramLines()
, or should this also be retrieved from the DataAPI somehow?