Rename "subcommand" to "command" (#204911)

* Rename "subcommand" to "command"

* Fix build
This commit is contained in:
Rob Lourens
2024-02-10 18:58:18 -03:00
committed by GitHub
parent 28cc5986c2
commit b2f1748501
5 changed files with 33 additions and 34 deletions

View File

@@ -37,8 +37,8 @@ suite('chat', () => {
return null;
});
agent.isDefault = true;
agent.subCommandProvider = {
provideSubCommands: (_token) => {
agent.commandProvider = {
provideCommands: (_token) => {
return [{ name: 'hello', description: 'Hello' }];
}
};
@@ -50,7 +50,7 @@ suite('chat', () => {
const deferred = getDeferredForRequest();
interactive.sendInteractiveRequestToProvider('provider', { message: '@agent /hello friend' });
const request = await deferred.p;
assert.deepStrictEqual(request.subCommand, 'hello');
assert.deepStrictEqual(request.command, 'hello');
assert.strictEqual(request.prompt, 'friend');
});
@@ -83,8 +83,8 @@ suite('chat', () => {
return { metadata: { key: 'value' } };
});
agent.isDefault = true;
agent.subCommandProvider = {
provideSubCommands: (_token) => {
agent.commandProvider = {
provideCommands: (_token) => {
return [{ name: 'hello', description: 'Hello' }];
}
};