-
Notifications
You must be signed in to change notification settings - Fork 97
feat(vscode): add .NET 10 support for custom code projects #8895
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
fd6682d
feat(vscode): add .NET 10 support for custom code projects
ccastrotrejo 9217dac
fix(vscode): restore .NET 8 test coverage and fix import regression
ccastrotrejo 1dcb201
fix(vscode): add dotnetJsonCli net10.0 asset and fix import regression
ccastrotrejo 8771150
refactor(vscode): map net10.0 to net8.0 dotnetJsonCli instead of dupl…
ccastrotrejo dd0b6f4
test(vscode): improve coverage for .NET 10 changes
ccastrotrejo 1611090
refactor(vscode): deduplicate usesPublishFolderProperty and guard nul…
ccastrotrejo d910e8a
test(vscode): add coverage for .NET 10 changes across 5 uncovered files
ccastrotrejo 5b7bdea
Merge branch 'main' of https://github.com/Azure/LogicAppsUX into ccas…
ccastrotrejo 18e5f25
Merge branch 'main' of https://github.com/Azure/LogicAppsUX into ccas…
ccastrotrejo 0a25ab6
refactor(vscode): update .NET 10 template and rename project templates
ccastrotrejo aecddcb
feat(vscode): add Program.cs generation for .NET 10 isolated worker m…
ccastrotrejo a3b701a
refactor(vscode): extract shared function project file utilities
ccastrotrejo f47d3c5
fix(vscode): add newline delimiter between version sources in getFram…
ccastrotrejo File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
48 changes: 48 additions & 0 deletions
48
.../createCustomCodeFunction/createCustomCodeFunctionSteps/__test__/functionFileStep.test.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,48 @@ | ||
| import { describe, it, expect, vi } from 'vitest'; | ||
| import { TargetFramework } from '@microsoft/vscode-extension-logic-apps'; | ||
|
|
||
| vi.mock('fs-extra'); | ||
| vi.mock('vscode'); | ||
| vi.mock('../../../../../extensionVariables', () => ({ | ||
| ext: { outputChannel: { appendLog: vi.fn() } }, | ||
| })); | ||
| vi.mock('../../../../../localize', () => ({ | ||
| localize: (_key: string, msg: string) => msg, | ||
| })); | ||
|
|
||
| import { FunctionFileStep } from '../functionFileStep'; | ||
|
|
||
| describe('FunctionFileStep', () => { | ||
| describe('csTemplateFileName mapping', () => { | ||
| it('should map Net10 to FunctionsFileNet10', () => { | ||
| const step = new FunctionFileStep(); | ||
| const mapping = (step as any).csTemplateFileName; | ||
| expect(mapping[TargetFramework.Net10]).toBe('FunctionsFileNet10'); | ||
| }); | ||
|
|
||
| it('should preserve Net8 mapping', () => { | ||
| const step = new FunctionFileStep(); | ||
| const mapping = (step as any).csTemplateFileName; | ||
| expect(mapping[TargetFramework.Net8]).toBe('FunctionsFileNet8'); | ||
| }); | ||
|
|
||
| it('should preserve NetFx mapping', () => { | ||
| const step = new FunctionFileStep(); | ||
| const mapping = (step as any).csTemplateFileName; | ||
| expect(mapping[TargetFramework.NetFx]).toBe('FunctionsFileNetFx'); | ||
| }); | ||
|
|
||
| it('should contain exactly three framework entries', () => { | ||
| const step = new FunctionFileStep(); | ||
| const mapping = (step as any).csTemplateFileName; | ||
| expect(Object.keys(mapping)).toHaveLength(3); | ||
| }); | ||
| }); | ||
|
|
||
| describe('shouldPrompt', () => { | ||
| it('should always return true', () => { | ||
| const step = new FunctionFileStep(); | ||
| expect(step.shouldPrompt()).toBe(true); | ||
| }); | ||
| }); | ||
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.