Skip to content

Commit 969e3d0

Browse files
authored
Trim windows- from codepage (#567)
1 parent d8ba052 commit 969e3d0

6 files changed

Lines changed: 34 additions & 6 deletions

File tree

CHANGELOG.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
# [1.4.33](https://github.com/kenherring/ablunit-test-runner/releases/tag/1.4.33) - 2026-04-15 (pre-release)
1+
# [1.4.35](https://github.com/kenherring/ablunit-test-runner/releases/tag/1.4.35) - 2026-04-15 (pre-release)
22

3+
* Trim `windows-` from codepage (#567)
34
* Clear environment variable when `initializationProcedure` is no longer set (#565)
45
* build(deps-dev): bump typescript-eslint from 8.58.0 to 8.58.1 (#563)
56
* Empty `dbConnections` array in openedge-project profile are not used (#560)
@@ -70,7 +71,7 @@
7071
* Bump esbuild from 0.27.0 to 0.27.1 (#457)
7172
* Bump jws from 3.2.2 to 3.2.3 in the npm_and_yarn group across 1 directory (#455)
7273

73-
**Full Changelog**: [1.4.4...1.4.33](https://github.com/kenherring/ablunit-test-runner/compare/1.4.4...1.4.33)
74+
**Full Changelog**: [1.4.4...1.4.35](https://github.com/kenherring/ablunit-test-runner/compare/1.4.4...1.4.35)
7475

7576
# [1.4.4](https://github.com/kenherring/ablunit-test-runner/releases/tag/1.4.4) - 2025-11-26 (pre-release)
7677

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "ablunit-test-runner",
33
"displayName": "ABLUnit Test Runner",
44
"description": "OpenEdge ABLUnit test runner for VSCode",
5-
"version": "1.4.33",
5+
"version": "1.4.35",
66
"engineStrict": true,
77
"galleryBanner": {
88
"color": "#007ACC",

src/parse/TestProfileParser.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,11 @@ export class RunConfig extends DefaultRunProfile {
228228
this.command.additionalArgs.push(...extraParameters)
229229
}
230230

231-
const charset = getProfileCharset(this.workspaceFolder.uri, this.profile.openedgeProjectProfile)
231+
let charset = getProfileCharset(this.workspaceFolder.uri, this.profile.openedgeProjectProfile)
232232
if (charset) {
233+
if (charset.startsWith('windows-')) {
234+
charset = charset.substring('windows-'.length)
235+
}
233236
if (this.command.additionalArgs.includes('-cpstream')) {
234237
log.warn('command.additionalArgs already contains -cpstream. Replacing with `-cpstream ' + charset)
235238
this.command.additionalArgs.splice(this.command.additionalArgs.indexOf('-cpstream'), 2, '-cpstream', charset)

test/suites/proj1.test.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -321,6 +321,21 @@ suite('proj1 - Extension Test Suite', () => {
321321
return p
322322
})
323323

324+
test('proj1.17 - codepage windows-1252', () => {
325+
if (process.platform !== 'win32') {
326+
log.info('skipping proj1.17 on Linux as it requires a windows environment')
327+
return
328+
}
329+
FileUtils.copyFile(Uri.joinPath(workspaceUri, 'openedge-project.proj1.17.json'), Uri.joinPath(workspaceUri, 'openedge-project.json'), { force: true })
330+
const p = runTestsInFile('classTest.cls')
331+
.then(() => {
332+
assert.tests.count(2)
333+
assert.tests.passed(2)
334+
return true
335+
})
336+
return p
337+
})
338+
324339
test('proj1.98 - check startup parmaeters for -y -yx', async () => {
325340
FileUtils.copyFile(Uri.joinPath(workspaceUri, 'openedge-project.proj1.98.json'), Uri.joinPath(workspaceUri, 'openedge-project.json'), { force: true })
326341
await runTestAtLine('import_charset.p', 68)
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"name": "proj1.17",
3+
"version": "1.0",
4+
"charset": "windows-1252",
5+
"buildDirectory": "build",
6+
"numThreads": 1,
7+
"dbConnections": [],
8+
"graphicalMode": false
9+
}

0 commit comments

Comments
 (0)