Skip to content
This repository has been archived by the owner on Jan 15, 2025. It is now read-only.

chore: fix dialog debugging #387

Merged
merged 1 commit into from
Nov 23, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ package-lock.json
#tsconfig.tsbuildinfo
tsconfig.tsbuildinfo

#vscode files
.vscode
packages/dialog/test/commands/dialog/projects/obj/Debug/netcoreapp2.1/LUISGen.csproj.CoreCompileInputs.cache
packages/dialog/test/commands/dialog/projects/obj/Debug/netcoreapp2.1/LUISGen.AssemblyInfo.cs
packages/dialog/test/commands/dialog/projects/obj/Debug/netcoreapp2.1/LUISGen.AssemblyInfoInputs.cache
Expand Down
78 changes: 42 additions & 36 deletions packages/dialog/.vscode/launch.json → .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,59 +8,67 @@
"type": "node",
"request": "launch",
"name": "Dialog Merge Tests",
"program": "${workspaceFolder}/node_modules/mocha/bin/_mocha",
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/packages/dialog/node_modules/mocha/bin/_mocha",
"cwd": "${workspaceFolder}/packages/dialog",
"args": [
"-u",
"tdd",
"--timeout",
"999999",
"--colors",
"${workspaceFolder}/test/commands/dialog/merge.test.ts"
"-g",
".*Test schema merge.*"
],
"internalConsoleOptions": "openOnSessionStart"
"internalConsoleOptions": "openOnSessionStart",
"sourceMaps": true,
"outFiles": [
"./package/dialog/lib/**"
]
},
{
"type": "node",
"request": "launch",
"name": "Dialog Verify Tests",
"program": "${workspaceFolder}/node_modules/mocha/bin/_mocha",
"cwd": "${workspaceFolder}",
"sourceMaps": false,
"program": "${workspaceFolder}/packages/dialog/node_modules/mocha/bin/_mocha",
"cwd": "${workspaceFolder}/packages/dialog",
"args": [
"-u",
"tdd",
"--timeout",
"999999",
"--colors",
"${workspaceFolder}/test/commands/dialog/verify.test.ts"
"-g",
".*dialog:verify.*"
],
"internalConsoleOptions": "openOnSessionStart"
"internalConsoleOptions": "openOnSessionStart",
"sourceMaps": true,
"outFiles": [
"./package/dialog/lib/**"
]
},
{
"type": "node",
"request": "launch",
"name": "Dialog Generator Tests",
"program": "${workspaceFolder}/node_modules/mocha/bin/_mocha",
"preLaunchTask": "tsc: build - tsconfig.json",
"program": "${workspaceFolder}/packages/dialog/node_modules/mocha/bin/_mocha",
"args": [
"-u",
"tdd",
"--timeout",
"999999",
"--colors",
"${workspaceFolder}/test/commands/dialog/generator.test.ts"
],
"internalConsoleOptions": "openOnSessionStart"
"internalConsoleOptions": "openOnSessionStart",
"sourceMaps": true,
"outFiles": [
"./package/dialog/lib/**"
]
},

// TODO: (chrande) Keeping these but they should probably be rewritten to work on more
// just chrismc's dev machine.
{
"type": "node",
"request": "launch",
"name": "BotBuilder schema",
"program": "${workspaceFolder}/bin/run",
"preLaunchTask": "tsc: build - tsconfig.json",
"program": "${workspaceFolder}/packages/dialog/bin/run",
"outFiles": [
"${workspaceFolder}/lib/**/*.js"
"${workspaceFolder}/packages/dialog/lib/**/*.js"
],
"args": [
"dialog:merge",
Expand All @@ -77,14 +85,14 @@
"type": "node",
"request": "launch",
"name": "Generate Sandwich Form",
"program": "${workspaceFolder}/bin/run",
"preLaunchTask": "tsc: build - tsconfig.json",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For this kind of thing it is definitely nice to be able to build before launching. What is the right pattern for this?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe ${defaultBuildTask}?

"program": "${workspaceFolder}/packages/dialog/bin/run",
"sourceMaps": true,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Find to be explicit, but isn't sourceMaps = true the default? For that matter, they don't even list it as an option in the docs. https://code.visualstudio.com/Docs/editor/debugging

"outFiles": [
"${workspaceFolder}/lib/**/*.js"
"${workspaceFolder}/packages/dialog/lib/**/*.js"
],
"args": [
"dialog:generate",
"${workspaceFolder}/test/commands/dialog/forms/sandwich.form.dialog",
"${workspaceFolder}/packages/dialog/test/commands/dialog/forms/sandwich.form.dialog",
"-o",
"${env:TEMP}/sandwich.out",
"--force",
Expand All @@ -96,14 +104,14 @@
"type": "node",
"request": "launch",
"name": "Generate Activity Form",
"program": "${workspaceFolder}/bin/run",
"program": "${workspaceFolder}/packages/dialog/bin/run",
"preLaunchTask": "tsc: build - tsconfig.json",
"outFiles": [
"${workspaceFolder}/lib/**/*.js"
"${workspaceFolder}/packages/dialog/lib/**/*.js"
],
"args": [
"dialog:generate",
"${workspaceFolder}/test/commands/dialog/forms/activity.form.dialog",
"${workspaceFolder}/packages/dialog/test/commands/dialog/forms/activity.form.dialog",
"-o",
"${env:TEMP}/activity.out",
"--force",
Expand All @@ -117,14 +125,13 @@
"type": "node",
"request": "launch",
"name": "Generate Contact Form",
"program": "${workspaceFolder}/bin/run",
"preLaunchTask": "tsc: build - tsconfig.json",
"program": "${workspaceFolder}/packages/dialog/bin/run",
"outFiles": [
"${workspaceFolder}/lib/**/*.js"
"${workspaceFolder}/packages/dialog/lib/**/*.js"
],
"args": [
"dialog:generate",
"${workspaceFolder}/test/commands/dialog/forms/contact.form.dialog",
"${workspaceFolder}/packages/dialog/test/commands/dialog/forms/contact.form.dialog",
"-o",
"${env:TEMP}/contact.out",
"--force",
Expand All @@ -138,14 +145,13 @@
"type": "node",
"request": "launch",
"name": "Generate Opportunity Form",
"program": "${workspaceFolder}/bin/run",
"preLaunchTask": "tsc: build - tsconfig.json",
"program": "${workspaceFolder}/packages/dialog/bin/run",
"outFiles": [
"${workspaceFolder}/lib/**/*.js"
"${workspaceFolder}/packages/dialog/lib/**/*.js"
],
"args": [
"dialog:generate",
"${workspaceFolder}/test/commands/dialog/forms/opportunity.form.dialog",
"${workspaceFolder}/packages/dialog/test/commands/dialog/forms/opportunity.form.dialog",
"-o",
"${env:TEMP}/opportunity.out",
"--force",
Expand Down
4 changes: 4 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"typescript.disableAutomaticTypeAcquisition": true,
"npm.packageManager": "npm"
}
Loading