File tree Expand file tree Collapse file tree 2 files changed +11
-3
lines changed
src/Markdown.MAML/Renderer Expand file tree Collapse file tree 2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public class MamlRenderer
18
18
private Stack < string > _tagStack = new Stack < string > ( ) ;
19
19
20
20
public const string XML_PREAMBULA = @"<?xml version=""1.0"" encoding=""utf-8""?>
21
- <helpItems schema=""maml"">
21
+ <helpItems xmlns=""http://msh"" schema=""maml"">
22
22
" ;
23
23
public const string COMMAND_PREAMBULA = @"<command:command xmlns:maml=""http://schemas.microsoft.com/maml/2004/10"" xmlns:command=""http://schemas.microsoft.com/maml/dev/command/2004/10"" xmlns:dev=""http://schemas.microsoft.com/maml/dev/2004/10"" xmlns:MSHelp=""http://msdn.microsoft.com/mshelp"">" ;
24
24
Original file line number Diff line number Diff line change @@ -394,15 +394,18 @@ Describe 'New-ExternalHelp' {
394
394
$Named
395
395
}
396
396
397
- It " generates right order for syntax " {
397
+ BeforeAll {
398
398
$a = @ {
399
399
command = ' Test-OrderFunction'
400
400
OutputFolder = ' TestDrive:\'
401
401
Force = $true
402
402
}
403
403
404
404
$file = New-MarkdownHelp @a
405
- $maml = $file | New-ExternalHelp - OutputPath " TestDrive:\" - Force
405
+ $maml = $file | New-ExternalHelp - OutputPath " TestDrive:\TestOrderFunction.xml" - Force
406
+ }
407
+
408
+ It " generates right order for syntax" {
406
409
$help = Get-HelpPreview - Path $maml
407
410
($help.Syntax.syntaxItem | measure).Count | Should Be 1
408
411
$names = $help.Syntax.syntaxItem.parameter.Name
@@ -411,6 +414,11 @@ Describe 'New-ExternalHelp' {
411
414
$names [1 ] | Should Be ' Third'
412
415
$names [2 ] | Should Be ' Named'
413
416
}
417
+
418
+ It " checks that xmlns 'http://msh' is present" {
419
+ $xml = [xml ] (Get-Content (Join-Path $TestDrive ' TestOrderFunction.xml' ))
420
+ $xml.helpItems.namespaceuri | Should Be ' http://msh'
421
+ }
414
422
}
415
423
416
424
# region PS Objects to MAML Model Tests
You can’t perform that action at this time.
0 commit comments