项目测试代码结构调整
This commit is contained in:
parent
7d0c1a0a3e
commit
6999fc30e8
@ -3,8 +3,8 @@ import * as assert from 'assert';
|
||||
// You can import and use all API from the 'vscode' module
|
||||
// as well as import your extension to test it
|
||||
import * as vscode from 'vscode';
|
||||
import testGroups from './test-case';
|
||||
import { TestCase, TestCaseGroup } from './types/TestCaseType';
|
||||
import { pathConvertTestGroups } from './test-case/path-convert-test-case';
|
||||
import { TestCase, TestCaseGroup } from './test-case/types/TestCaseType';
|
||||
import { transformMutliLineText, transformText } from '../utils/transform';
|
||||
import { caseConversion } from '../core/variable-convert/conversion';
|
||||
import { SupportCase } from '../core/variable-convert/types/SupportCaseType';
|
||||
@ -22,10 +22,15 @@ suite('Extension Test Suite', () => {
|
||||
});
|
||||
*/
|
||||
|
||||
suite('Extension Test: run test case', () => {
|
||||
/**
|
||||
* 变量转换 测试函数
|
||||
*
|
||||
* @since 2024-04-02
|
||||
*/
|
||||
suite('Extension Test: run variable convert test case', () => {
|
||||
vscode.window.showInformationMessage('Start all tests.');
|
||||
|
||||
const groups: Array<TestCaseGroup> = testGroups;
|
||||
const groups: Array<TestCaseGroup> = pathConvertTestGroups;
|
||||
for (const testGroup of groups) {
|
||||
const testTitle = testGroup.testTitle;
|
||||
const testCases: Array<TestCase> = testGroup.cases;
|
||||
|
@ -3,7 +3,7 @@ import { TestCaseGroup } from "./types/TestCaseType";
|
||||
const LF = '\n';
|
||||
const CRLF = '\r\n';
|
||||
|
||||
const testGroups: Array<TestCaseGroup> = [
|
||||
export const pathConvertTestGroups: Array<TestCaseGroup> = [
|
||||
{
|
||||
group: 'Input validation',
|
||||
testTitle: 'Input validation (输入有效性验证)',
|
||||
@ -1095,5 +1095,3 @@ const testGroups: Array<TestCaseGroup> = [
|
||||
},
|
||||
// add more cases...
|
||||
];
|
||||
|
||||
export default testGroups;
|
@ -1,4 +1,4 @@
|
||||
import { EOL } from "../../types/EOLType";
|
||||
import { EOL } from "../../../types/EOLType";
|
||||
|
||||
export type TestCaseGroup = {
|
||||
group: string
|
Loading…
Reference in New Issue
Block a user