Skip to content

Commit

Permalink
feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
jpogran committed Nov 25, 2024
1 parent 74035f2 commit b92ec55
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 30 deletions.
2 changes: 1 addition & 1 deletion src/api/terraformCloud/organization.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { paginationMeta, paginationParams } from './pagination';
import { searchQueryParams } from './filter';
import { errors } from './errors';

export const organization = z.object({
const organization = z.object({
id: z.string(),
attributes: z.object({
'external-id': z.string(),
Expand Down
2 changes: 1 addition & 1 deletion src/providers/tfc/applyProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ import { Writable } from 'stream';
import axios from 'axios';
import TelemetryReporter from '@vscode/extension-telemetry';

import { TerraformCloudAuthenticationProvider } from './authenticationProvider';
import { ZodiosError } from '@zodios/core';
import { handleAuthError, handleZodiosError } from './uiHelpers';
import { GetChangeActionIcon } from './helpers';
import { AppliedChange, ChangeSummary, Diagnostic, LogLine, Outputs } from '../../api/terraformCloud/log';
import { ApplyTreeItem } from './runProvider';
import { OutputsItem, DiagnosticsItem, DiagnosticSummary, ItemWithChildren, isItemWithChildren } from './logHelpers';
import { TerraformCloudAuthenticationProvider } from './authenticationProvider';

export class ApplyTreeDataProvider implements vscode.TreeDataProvider<vscode.TreeItem>, vscode.Disposable {
private readonly didChangeTreeData = new vscode.EventEmitter<vscode.TreeItem | undefined>();
Expand Down
3 changes: 1 addition & 2 deletions src/providers/tfc/planProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,13 @@ import { Writable } from 'stream';
import axios from 'axios';
import TelemetryReporter from '@vscode/extension-telemetry';

// import { TerraformCloudAuthenticationProvider } from './authenticationProvider';
import { TerraformCloudAuthenticationProvider } from './authenticationProvider';
import { ZodiosError } from '@zodios/core';
import { handleAuthError, handleZodiosError } from './uiHelpers';
import { GetChangeActionIcon, GetDriftChangeActionMessage } from './helpers';
import { Change, ChangeSummary, Diagnostic, DriftSummary, LogLine, Outputs } from '../../api/terraformCloud/log';
import { PlanTreeItem } from './runProvider';
import { DiagnosticSummary, DiagnosticsItem, OutputsItem, isItemWithChildren, ItemWithChildren } from './logHelpers';
import { TerraformCloudAuthenticationProvider } from './authenticationProvider';

export class PlanTreeDataProvider implements vscode.TreeDataProvider<vscode.TreeItem>, vscode.Disposable {
private readonly didChangeTreeData = new vscode.EventEmitter<vscode.TreeItem | undefined>();
Expand Down
2 changes: 1 addition & 1 deletion src/providers/tfc/runProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import TelemetryReporter from '@vscode/extension-telemetry';
import semver from 'semver';

import { TerraformCloudWebUrl, apiClient } from '../../api/terraformCloud';
import { TerraformCloudAuthenticationProvider } from './authenticationProvider';
import { RUN_SOURCE, RunAttributes, TRIGGER_REASON } from '../../api/terraformCloud/run';
import { WorkspaceTreeItem } from './workspaceProvider';
import { GetPlanApplyStatusIcon, GetRunStatusIcon, GetRunStatusMessage, RelativeTimeFormat } from './helpers';
Expand All @@ -20,7 +21,6 @@ import { ApplyAttributes } from '../../api/terraformCloud/apply';
import { CONFIGURATION_SOURCE } from '../../api/terraformCloud/configurationVersion';
import { PlanTreeDataProvider } from './planProvider';
import { ApplyTreeDataProvider } from './applyProvider';
import { TerraformCloudAuthenticationProvider } from './authenticationProvider';

export class RunTreeDataProvider implements vscode.TreeDataProvider<TFCRunTreeItem>, vscode.Disposable {
private readonly didChangeTreeData = new vscode.EventEmitter<undefined | TFCRunTreeItem>();
Expand Down
2 changes: 1 addition & 1 deletion src/providers/tfc/workspaceProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import TelemetryReporter from '@vscode/extension-telemetry';

import { RunTreeDataProvider } from './runProvider';
import { apiClient, TerraformCloudWebUrl } from '../../api/terraformCloud';
import { TerraformCloudAuthenticationProvider } from './authenticationProvider';
import { ProjectsAPIResource, ResetProjectItem } from './workspaceFilters';
import { GetRunStatusIcon, GetRunStatusMessage, RelativeTimeFormat } from './helpers';
import { WorkspaceAttributes } from '../../api/terraformCloud/workspace';
Expand All @@ -16,7 +17,6 @@ import { APIQuickPick, handleAuthError, handleZodiosError } from './uiHelpers';
import { isErrorFromAlias, ZodiosError } from '@zodios/core';
import axios from 'axios';
import { apiErrorsToString } from '../../api/terraformCloud/errors';
import { TerraformCloudAuthenticationProvider } from './authenticationProvider';

export class WorkspaceTreeDataProvider implements vscode.TreeDataProvider<vscode.TreeItem>, vscode.Disposable {
private readonly didChangeTreeData = new vscode.EventEmitter<undefined | vscode.TreeItem>();
Expand Down
19 changes: 0 additions & 19 deletions src/test/e2e/mockSetup.ts

This file was deleted.

8 changes: 4 additions & 4 deletions src/test/e2e/specs/extension.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ import {
ExtensionsViewItem,
ExtensionsViewSection,
BottomBarPanel,
OutputView,
} from 'vscode-extension-tester';
import { expect, assert } from 'chai';
import { expect } from 'chai';
import pjson from '../../../../package.json';

describe('VS Code Extension Testing', () => {
let terraformExtension: ExtensionsViewItem;
Expand Down Expand Up @@ -48,8 +48,8 @@ describe('VS Code Extension Testing', () => {
const version = await terraformExtension.getVersion();

// in this case we are comparing the results against the values in package.json
expect(author).equals('hashicorp');
expect(version).equals('2.34.2024101517');
expect(author).equals(pjson.publisher);
expect(version).equals(pjson.version);
});

it('should be able to load VSCode', async () => {
Expand Down
4 changes: 3 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
"sourceMap": true,
"strict": true,
"skipLibCheck": true,
"allowSyntheticDefaultImports": true
"allowSyntheticDefaultImports": true,

"resolveJsonModule": true
},
"include": ["src"],
"exclude": ["node_modules", ".vscode-test", ".vscode-test-web", ".test-storage", ".test-extensions"]
Expand Down

0 comments on commit b92ec55

Please sign in to comment.