Skip to content

Commit 508cdff

Browse files
committed
Merge remote-tracking branch 'origin/master' into cli_tool_add_feature
2 parents a5c0707 + 2d92bb6 commit 508cdff

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

HarmonyCoreCodeGen.Core/Generator/ODataGenerator.dbl

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,24 @@ namespace HarmonyCoreGenerator.Generator
5858
result.Add(StructureTaskHelper(targetSolution, "Generate OData Postman tests", "", targetSolution.SolutionFolder, true, ^nameof(ODataGenerator), new string[#] { "ODataPostManTests", "PostManDevelopmentEnvironment" }, ^null))
5959
end
6060

61+
;; Authentication
62+
63+
if (targetSolution.CustomAuthentication ?? false)
64+
begin
65+
;; Add AuthenticationModels.dbl if it doesn't exist
66+
data authModelTask = StructureTaskHelper(targetSolution, "Generate custom authentication", targetSolution.ModelsNamespace, targetSolution.ModelsFolder, true, ^nameof(ODataGenerator), new string[#] { "ODataCustomAuthModels" }, ^null)
67+
authModelTask.ReplaceFiles = false
68+
result.Add(authModelTask)
69+
;; Add AuthenticationController.dbl if it doesn't exist
70+
data authControllerTask = StructureTaskHelper(targetSolution, "Generate custom authentication", targetSolution.ControllersNamespace, targetSolution.ControllersFolder, true, ^nameof(ODataGenerator), new string[#] { "ODataCustomAuthController" }, ^null)
71+
authControllerTask.ReplaceFiles = false
72+
result.Add(authControllerTask)
73+
;; Add AuthenticationTools.dbl if it doesn't exist
74+
data authToolsTask = StructureTaskHelper(targetSolution, "Generate custom authentication", targetSolution.ControllersNamespace, targetSolution.ControllersFolder, true, ^nameof(ODataGenerator), new string[#] { "ODataCustomAuthTools" }, ^null)
75+
authToolsTask.ReplaceFiles = false
76+
result.Add(authToolsTask)
77+
end
78+
6179
;;---------------------------------------------------------------------------------------------
6280
;; Unit tests
6381

0 commit comments

Comments
 (0)