Commit fce9b0cee0728e53e77618c5cc65dde2b6369410

Daniel Flint 2015-08-29T09:20:35

Remaining test cases for PowerShell

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
diff --git a/components/prism-powershell.js b/components/prism-powershell.js
index 2cff8bd..235d754 100644
--- a/components/prism-powershell.js
+++ b/components/prism-powershell.js
@@ -25,8 +25,6 @@ Prism.languages.powershell = {
 	'namespace': /\[[a-z][\w\W]*?\]/i,
 	'boolean': /\$(true|false)\b/i,
 	'variable': /\$\w+\b/i,
-	// per http://technet.microsoft.com/en-us/library/hh847744.aspx
-	'keyword': /\b(Begin|Break|Catch|Class|Continue|Data|Define|Do|DynamicParam|Else|ElseIf|End|Exit|Filter|Finally|For|ForEach|From|Function|If|InlineScript|Parallel|Param|Process|Return|Sequence|Switch|Throw|Trap|Try|Until|Using|Var|While|Workflow)\b/i,
 	// Cmdlets and aliases. Aliases should come last, otherwise "write" gets preferred over "write-host" for example
 	// Get-Command | ?{ $_.ModuleName -match "Microsoft.PowerShell.(Util|Core|Management)" }
 	// Get-Alias | ?{ $_.ReferencedCommand.Module.Name -match "Microsoft.PowerShell.(Util|Core|Management)" }
@@ -34,8 +32,10 @@ Prism.languages.powershell = {
 		/\b(Add-(Computer|Content|History|Member|PSSnapin|Type)|Checkpoint-Computer|Clear-(Content|EventLog|History|Item|ItemProperty|Variable)|Compare-Object|Complete-Transaction|Connect-PSSession|ConvertFrom-(Csv|Json|StringData)|Convert-Path|ConvertTo-(Csv|Html|Json|Xml)|Copy-(Item|ItemProperty)|Debug-Process|Disable-(ComputerRestore|PSBreakpoint|PSRemoting|PSSessionConfiguration)|Disconnect-PSSession|Enable-(ComputerRestore|PSBreakpoint|PSRemoting|PSSessionConfiguration)|Enter-PSSession|Exit-PSSession|Export-(Alias|Clixml|Console|Csv|FormatData|ModuleMember|PSSession)|ForEach-Object|Format-(Custom|List|Table|Wide)|Get-(Alias|ChildItem|Command|ComputerRestorePoint|Content|ControlPanelItem|Culture|Date|Event|EventLog|EventSubscriber|FormatData|Help|History|Host|HotFix|Item|ItemProperty|Job|Location|Member|Module|Process|PSBreakpoint|PSCallStack|PSDrive|PSProvider|PSSession|PSSessionConfiguration|PSSnapin|Random|Service|TraceSource|Transaction|TypeData|UICulture|Unique|Variable|WmiObject)|Group-Object|Import-(Alias|Clixml|Csv|LocalizedData|Module|PSSession)|Invoke-(Command|Expression|History|Item|RestMethod|WebRequest|WmiMethod)|Join-Path|Limit-EventLog|Measure-(Command|Object)|Move-(Item|ItemProperty)|New-(Alias|Event|EventLog|Item|ItemProperty|Module|ModuleManifest|Object|PSDrive|PSSession|PSSessionConfigurationFile|PSSessionOption|PSTransportOption|Service|TimeSpan|Variable|WebServiceProxy)|Out-(Default|File|GridView|Host|Null|Printer|String)|Pop-Location|Push-Location|Read-Host|Receive-(Job|PSSession)|Register-(EngineEvent|ObjectEvent|PSSessionConfiguration|WmiEvent)|Remove-(Computer|Event|EventLog|Item|ItemProperty|Job|Module|PSBreakpoint|PSDrive|PSSession|PSSnapin|TypeData|Variable|WmiObject)|Rename-(Computer|Item|ItemProperty)|Reset-ComputerMachinePassword|Resolve-Path|Restart-(Computer|Service)|Restore-Computer|Resume-(Job|Service)|Save-Help|Select-(Object|String|Xml)|Send-MailMessage|Set-(Alias|Content|Date|Item|ItemProperty|Location|PSBreakpoint|PSDebug|PSSessionConfiguration|Service|StrictMode|TraceSource|Variable|WmiInstance)|Show-(Command|ControlPanelItem|EventLog)|Sort-Object|Split-Path|Start-(Job|Process|Service|Sleep|Transaction)|Stop-(Computer|Job|Process|Service)|Suspend-(Job|Service)|Tee-Object|Test-(ComputerSecureChannel|Connection|ModuleManifest|Path|PSSessionConfigurationFile)|Trace-Command|Unblock-File|Undo-Transaction|Unregister-(Event|PSSessionConfiguration)|Update-(FormatData|Help|List|TypeData)|Use-Transaction|Wait-(Event|Job|Process)|Where-Object|Write-(Debug|Error|EventLog|Host|Output|Progress|Verbose|Warning))\b/i,
 		/\b(ac|cat|chdir|clc|cli|clp|clv|compare|copy|cp|cpi|cpp|cvpa|dbp|del|diff|dir|ebp|echo|epal|epcsv|epsn|erase|fc|fl|ft|fw|gal|gbp|gc|gci|gcs|gdr|gi|gl|gm|gp|gps|group|gsv|gu|gv|gwmi|iex|ii|ipal|ipcsv|ipsn|irm|iwmi|iwr|kill|lp|ls|measure|mi|mount|move|mp|mv|nal|ndr|ni|nv|ogv|popd|ps|pushd|pwd|rbp|rd|rdr|ren|ri|rm|rmdir|rni|rnp|rp|rv|rvpa|rwmi|sal|saps|sasv|sbp|sc|select|set|shcm|si|sl|sleep|sls|sort|sp|spps|spsv|start|sv|swmi|tee|trcm|type|write)\b/i
 	],
+	// per http://technet.microsoft.com/en-us/library/hh847744.aspx
+	'keyword': /\b(Begin|Break|Catch|Class|Continue|Data|Define|Do|DynamicParam|Else|ElseIf|End|Exit|Filter|Finally|For|ForEach|From|Function|If|InlineScript|Parallel|Param|Process|Return|Sequence|Switch|Throw|Trap|Try|Until|Using|Var|While|Workflow)\b/i,
 	'operator': {
-		pattern: /(\W)(!|-(eq|ne|gt|ge|lt|le|sh[lr]|not|b?(and|x?or)|(Not)?(Like|Match|Contains|In)|Replace|Join|is(Not)?|as)\b|[-+]{2}|[-+*\/%]=?)/i,
+		pattern: /(\W?)(!|-(eq|ne|gt|ge|lt|le|sh[lr]|not|b?(and|x?or)|(Not)?(Like|Match|Contains|In)|Replace|Join|is(Not)?|as)\b|[-+]{2}|[-+*\/%]=?)/i,
 		lookbehind: true
 	},
 	'punctuation': /[|{}[\];(),.]/
diff --git a/components/prism-powershell.min.js b/components/prism-powershell.min.js
index 84949d0..111ae81 100644
--- a/components/prism-powershell.min.js
+++ b/components/prism-powershell.min.js
@@ -1 +1 @@
-Prism.languages.powershell={comment:[{pattern:/(^|[^`])<#[\w\W]*?#>/,lookbehind:!0},{pattern:/(^|[^`])#.*?(\r?\n|$)/,lookbehind:!0}],string:[{pattern:/"(`?[\w\W])*?"/m,inside:{"function":{pattern:/[^`]\$\(.*?\)/,inside:{}}}},/'([\w\W])*?'/m],namespace:/\[[a-z][\w\W]*?\]/i,"boolean":/\$(true|false)\b/i,variable:/\$\w+\b/i,keyword:/\b(Begin|Break|Catch|Class|Continue|Data|Define|Do|DynamicParam|Else|ElseIf|End|Exit|Filter|Finally|For|ForEach|From|Function|If|InlineScript|Parallel|Param|Process|Return|Sequence|Switch|Throw|Trap|Try|Until|Using|Var|While|Workflow)\b/i,"function":[/\b(Add-(Computer|Content|History|Member|PSSnapin|Type)|Checkpoint-Computer|Clear-(Content|EventLog|History|Item|ItemProperty|Variable)|Compare-Object|Complete-Transaction|Connect-PSSession|ConvertFrom-(Csv|Json|StringData)|Convert-Path|ConvertTo-(Csv|Html|Json|Xml)|Copy-(Item|ItemProperty)|Debug-Process|Disable-(ComputerRestore|PSBreakpoint|PSRemoting|PSSessionConfiguration)|Disconnect-PSSession|Enable-(ComputerRestore|PSBreakpoint|PSRemoting|PSSessionConfiguration)|Enter-PSSession|Exit-PSSession|Export-(Alias|Clixml|Console|Csv|FormatData|ModuleMember|PSSession)|ForEach-Object|Format-(Custom|List|Table|Wide)|Get-(Alias|ChildItem|Command|ComputerRestorePoint|Content|ControlPanelItem|Culture|Date|Event|EventLog|EventSubscriber|FormatData|Help|History|Host|HotFix|Item|ItemProperty|Job|Location|Member|Module|Process|PSBreakpoint|PSCallStack|PSDrive|PSProvider|PSSession|PSSessionConfiguration|PSSnapin|Random|Service|TraceSource|Transaction|TypeData|UICulture|Unique|Variable|WmiObject)|Group-Object|Import-(Alias|Clixml|Csv|LocalizedData|Module|PSSession)|Invoke-(Command|Expression|History|Item|RestMethod|WebRequest|WmiMethod)|Join-Path|Limit-EventLog|Measure-(Command|Object)|Move-(Item|ItemProperty)|New-(Alias|Event|EventLog|Item|ItemProperty|Module|ModuleManifest|Object|PSDrive|PSSession|PSSessionConfigurationFile|PSSessionOption|PSTransportOption|Service|TimeSpan|Variable|WebServiceProxy)|Out-(Default|File|GridView|Host|Null|Printer|String)|Pop-Location|Push-Location|Read-Host|Receive-(Job|PSSession)|Register-(EngineEvent|ObjectEvent|PSSessionConfiguration|WmiEvent)|Remove-(Computer|Event|EventLog|Item|ItemProperty|Job|Module|PSBreakpoint|PSDrive|PSSession|PSSnapin|TypeData|Variable|WmiObject)|Rename-(Computer|Item|ItemProperty)|Reset-ComputerMachinePassword|Resolve-Path|Restart-(Computer|Service)|Restore-Computer|Resume-(Job|Service)|Save-Help|Select-(Object|String|Xml)|Send-MailMessage|Set-(Alias|Content|Date|Item|ItemProperty|Location|PSBreakpoint|PSDebug|PSSessionConfiguration|Service|StrictMode|TraceSource|Variable|WmiInstance)|Show-(Command|ControlPanelItem|EventLog)|Sort-Object|Split-Path|Start-(Job|Process|Service|Sleep|Transaction)|Stop-(Computer|Job|Process|Service)|Suspend-(Job|Service)|Tee-Object|Test-(ComputerSecureChannel|Connection|ModuleManifest|Path|PSSessionConfigurationFile)|Trace-Command|Unblock-File|Undo-Transaction|Unregister-(Event|PSSessionConfiguration)|Update-(FormatData|Help|List|TypeData)|Use-Transaction|Wait-(Event|Job|Process)|Where-Object|Write-(Debug|Error|EventLog|Host|Output|Progress|Verbose|Warning))\b/i,/\b(ac|cat|chdir|clc|cli|clp|clv|compare|copy|cp|cpi|cpp|cvpa|dbp|del|diff|dir|ebp|echo|epal|epcsv|epsn|erase|fc|fl|ft|fw|gal|gbp|gc|gci|gcs|gdr|gi|gl|gm|gp|gps|group|gsv|gu|gv|gwmi|iex|ii|ipal|ipcsv|ipsn|irm|iwmi|iwr|kill|lp|ls|measure|mi|mount|move|mp|mv|nal|ndr|ni|nv|ogv|popd|ps|pushd|pwd|rbp|rd|rdr|ren|ri|rm|rmdir|rni|rnp|rp|rv|rvpa|rwmi|sal|saps|sasv|sbp|sc|select|set|shcm|si|sl|sleep|sls|sort|sp|spps|spsv|start|sv|swmi|tee|trcm|type|write)\b/i],operator:{pattern:/(\W)(!|-(eq|ne|gt|ge|lt|le|sh[lr]|not|b?(and|x?or)|(Not)?(Like|Match|Contains|In)|Replace|Join|is(Not)?|as)\b|[-+]{2}|[-+*\/%]=?)/i,lookbehind:!0},punctuation:/[|{}[\];(),.]/},Prism.languages.powershell.string[0].inside.boolean=Prism.languages.powershell.boolean,Prism.languages.powershell.string[0].inside.variable=Prism.languages.powershell.variable,Prism.languages.powershell.string[0].inside.function.inside=Prism.util.clone(Prism.languages.powershell);
\ No newline at end of file
+Prism.languages.powershell={comment:[{pattern:/(^|[^`])<#[\w\W]*?#>/,lookbehind:!0},{pattern:/(^|[^`])#.*?(\r?\n|$)/,lookbehind:!0}],string:[{pattern:/"(`?[\w\W])*?"/m,inside:{"function":{pattern:/[^`]\$\(.*?\)/,inside:{}}}},/'([\w\W])*?'/m],namespace:/\[[a-z][\w\W]*?\]/i,"boolean":/\$(true|false)\b/i,variable:/\$\w+\b/i,"function":[/\b(Add-(Computer|Content|History|Member|PSSnapin|Type)|Checkpoint-Computer|Clear-(Content|EventLog|History|Item|ItemProperty|Variable)|Compare-Object|Complete-Transaction|Connect-PSSession|ConvertFrom-(Csv|Json|StringData)|Convert-Path|ConvertTo-(Csv|Html|Json|Xml)|Copy-(Item|ItemProperty)|Debug-Process|Disable-(ComputerRestore|PSBreakpoint|PSRemoting|PSSessionConfiguration)|Disconnect-PSSession|Enable-(ComputerRestore|PSBreakpoint|PSRemoting|PSSessionConfiguration)|Enter-PSSession|Exit-PSSession|Export-(Alias|Clixml|Console|Csv|FormatData|ModuleMember|PSSession)|ForEach-Object|Format-(Custom|List|Table|Wide)|Get-(Alias|ChildItem|Command|ComputerRestorePoint|Content|ControlPanelItem|Culture|Date|Event|EventLog|EventSubscriber|FormatData|Help|History|Host|HotFix|Item|ItemProperty|Job|Location|Member|Module|Process|PSBreakpoint|PSCallStack|PSDrive|PSProvider|PSSession|PSSessionConfiguration|PSSnapin|Random|Service|TraceSource|Transaction|TypeData|UICulture|Unique|Variable|WmiObject)|Group-Object|Import-(Alias|Clixml|Csv|LocalizedData|Module|PSSession)|Invoke-(Command|Expression|History|Item|RestMethod|WebRequest|WmiMethod)|Join-Path|Limit-EventLog|Measure-(Command|Object)|Move-(Item|ItemProperty)|New-(Alias|Event|EventLog|Item|ItemProperty|Module|ModuleManifest|Object|PSDrive|PSSession|PSSessionConfigurationFile|PSSessionOption|PSTransportOption|Service|TimeSpan|Variable|WebServiceProxy)|Out-(Default|File|GridView|Host|Null|Printer|String)|Pop-Location|Push-Location|Read-Host|Receive-(Job|PSSession)|Register-(EngineEvent|ObjectEvent|PSSessionConfiguration|WmiEvent)|Remove-(Computer|Event|EventLog|Item|ItemProperty|Job|Module|PSBreakpoint|PSDrive|PSSession|PSSnapin|TypeData|Variable|WmiObject)|Rename-(Computer|Item|ItemProperty)|Reset-ComputerMachinePassword|Resolve-Path|Restart-(Computer|Service)|Restore-Computer|Resume-(Job|Service)|Save-Help|Select-(Object|String|Xml)|Send-MailMessage|Set-(Alias|Content|Date|Item|ItemProperty|Location|PSBreakpoint|PSDebug|PSSessionConfiguration|Service|StrictMode|TraceSource|Variable|WmiInstance)|Show-(Command|ControlPanelItem|EventLog)|Sort-Object|Split-Path|Start-(Job|Process|Service|Sleep|Transaction)|Stop-(Computer|Job|Process|Service)|Suspend-(Job|Service)|Tee-Object|Test-(ComputerSecureChannel|Connection|ModuleManifest|Path|PSSessionConfigurationFile)|Trace-Command|Unblock-File|Undo-Transaction|Unregister-(Event|PSSessionConfiguration)|Update-(FormatData|Help|List|TypeData)|Use-Transaction|Wait-(Event|Job|Process)|Where-Object|Write-(Debug|Error|EventLog|Host|Output|Progress|Verbose|Warning))\b/i,/\b(ac|cat|chdir|clc|cli|clp|clv|compare|copy|cp|cpi|cpp|cvpa|dbp|del|diff|dir|ebp|echo|epal|epcsv|epsn|erase|fc|fl|ft|fw|gal|gbp|gc|gci|gcs|gdr|gi|gl|gm|gp|gps|group|gsv|gu|gv|gwmi|iex|ii|ipal|ipcsv|ipsn|irm|iwmi|iwr|kill|lp|ls|measure|mi|mount|move|mp|mv|nal|ndr|ni|nv|ogv|popd|ps|pushd|pwd|rbp|rd|rdr|ren|ri|rm|rmdir|rni|rnp|rp|rv|rvpa|rwmi|sal|saps|sasv|sbp|sc|select|set|shcm|si|sl|sleep|sls|sort|sp|spps|spsv|start|sv|swmi|tee|trcm|type|write)\b/i],keyword:/\b(Begin|Break|Catch|Class|Continue|Data|Define|Do|DynamicParam|Else|ElseIf|End|Exit|Filter|Finally|For|ForEach|From|Function|If|InlineScript|Parallel|Param|Process|Return|Sequence|Switch|Throw|Trap|Try|Until|Using|Var|While|Workflow)\b/i,operator:{pattern:/(\W?)(!|-(eq|ne|gt|ge|lt|le|sh[lr]|not|b?(and|x?or)|(Not)?(Like|Match|Contains|In)|Replace|Join|is(Not)?|as)\b|[-+]{2}|[-+*\/%]=?)/i,lookbehind:!0},punctuation:/[|{}[\];(),.]/},Prism.languages.powershell.string[0].inside.boolean=Prism.languages.powershell.boolean,Prism.languages.powershell.string[0].inside.variable=Prism.languages.powershell.variable,Prism.languages.powershell.string[0].inside.function.inside=Prism.util.clone(Prism.languages.powershell);
\ No newline at end of file
diff --git a/tests/languages/powershell/boolean_feature.test b/tests/languages/powershell/boolean_feature.test
new file mode 100644
index 0000000..aae876a
--- /dev/null
+++ b/tests/languages/powershell/boolean_feature.test
@@ -0,0 +1,18 @@
+$true $True $TRUE
+$false $False $FALSE
+
+----------------------------------------------------
+
+[
+	["boolean", "$true"],
+	["boolean", "$True"],
+	["boolean", "$TRUE"],
+	
+	["boolean", "$false"],
+	["boolean", "$False"],
+	["boolean", "$FALSE"]
+
+]
+----------------------------------------------------
+
+Testing Booleans
\ No newline at end of file
diff --git a/tests/languages/powershell/function_feature.test b/tests/languages/powershell/function_feature.test
new file mode 100644
index 0000000..e7b07af
--- /dev/null
+++ b/tests/languages/powershell/function_feature.test
@@ -0,0 +1,398 @@
+ac cat chdir clc cli clp clv compare copy cp cpi cpp cvpa dbp del diff dir ebp
+echo epal epcsv epsn erase fc fl ft fw gal gbp gc gci gcs gdr gi gl gm gp gps
+group gsv gu gv gwmi iex ii ipal ipcsv ipsn irm iwmi iwr kill lp ls measure mi
+mount move mp mv nal ndr ni nv ogv popd ps pushd pwd rbp rd rdr ren ri rm rmdir
+rni rnp rp rv rvpa rwmi sal saps sasv sbp sc select set shcm si sl sleep sls
+sort sp spps spsv start sv swmi tee trcm type write
+
+Add-Computer Add-Content Add-History Add-Member Add-PSSnapin Add-Type
+Checkpoint-Computer Clear-Content Clear-EventLog Clear-History Clear-Item
+Clear-ItemProperty Clear-Variable Compare-Object Complete-Transaction
+Connect-PSSession ConvertFrom-Csv ConvertFrom-Json ConvertFrom-StringData
+Convert-Path ConvertTo-Csv ConvertTo-Html ConvertTo-Json ConvertTo-Xml
+Copy-Item Copy-ItemProperty Debug-Process Disable-ComputerRestore
+Disable-PSBreakpoint Disable-PSRemoting Disable-PSSessionConfiguration
+Disconnect-PSSession Enable-ComputerRestore Enable-PSBreakpoint
+Enable-PSRemoting Enable-PSSessionConfiguration Enter-PSSession Exit-PSSession
+Export-Alias Export-Clixml Export-Console Export-Csv Export-FormatData
+Export-ModuleMember Export-PSSession ForEach-Object Format-Custom Format-List
+Format-Table Format-Wide Get-Alias Get-ChildItem Get-Command
+Get-ComputerRestorePoint Get-Content Get-ControlPanelItem Get-Culture Get-Date
+Get-Event Get-EventLog Get-EventSubscriber Get-FormatData Get-Help Get-History
+Get-Host Get-HotFix Get-Item Get-ItemProperty Get-Job Get-Location Get-Member
+Get-Module Get-Process Get-PSBreakpoint Get-PSCallStack Get-PSDrive
+Get-PSProvider Get-PSSession Get-PSSessionConfiguration Get-PSSnapin Get-Random
+Get-Service Get-TraceSource Get-Transaction Get-TypeData Get-UICulture
+Get-Unique Get-Variable Get-WmiObject Group-Object Import-Alias Import-Clixml
+Import-Csv Import-LocalizedData Import-Module Import-PSSession Invoke-Command
+Invoke-Expression Invoke-History Invoke-Item Invoke-RestMethod Invoke-WebRequest
+Invoke-WmiMethod Join-Path Limit-EventLog Measure-Command Measure-Object
+Move-Item Move-ItemProperty New-Alias New-Event New-EventLog New-Item
+New-ItemProperty New-Module New-ModuleManifest New-Object New-PSDrive
+New-PSSession New-PSSessionConfigurationFile New-PSSessionOption
+New-PSTransportOption New-Service New-TimeSpan New-Variable New-WebServiceProxy
+Out-Default Out-File Out-GridView Out-Host Out-Null Out-Printer Out-String
+Pop-Location Push-Location Read-Host Receive-Job Receive-PSSession
+Register-EngineEvent Register-ObjectEvent Register-PSSessionConfiguration
+Register-WmiEvent Remove-Computer Remove-Event Remove-EventLog Remove-Item
+Remove-ItemProperty Remove-Job Remove-Module Remove-PSBreakpoint Remove-PSDrive
+Remove-PSSession Remove-PSSnapin Remove-TypeData Remove-Variable
+Remove-WmiObject Rename-Computer Rename-Item Rename-ItemProperty
+Reset-ComputerMachinePassword Resolve-Path Restart-Computer Restart-Service
+Restore-Computer Resume-Job Resume-Service Save-Help Select-Object Select-String
+Select-Xml Send-MailMessage Set-Alias Set-Content Set-Date Set-Item
+Set-ItemProperty Set-Location Set-PSBreakpoint Set-PSDebug
+Set-PSSessionConfiguration Set-Service Set-StrictMode Set-TraceSource
+Set-Variable Set-WmiInstance Show-Command Show-ControlPanelItem Show-EventLog
+Sort-Object Split-Path Start-Job Start-Process Start-Service Start-Sleep
+Start-Transaction Stop-Computer Stop-Job Stop-Process Stop-Service Suspend-Job
+Suspend-Service Tee-Object Test-ComputerSecureChannel Test-Connection
+Test-ModuleManifest Test-Path Test-PSSessionConfigurationFile Trace-Command
+Unblock-File Undo-Transaction Unregister-Event
+Unregister-PSSessionConfiguration Update-FormatData Update-Help Update-List
+Update-TypeData Use-Transaction Wait-Event Wait-Job Wait-Process Where-Object
+Write-Debug Write-Error Write-EventLog Write-Host Write-Output Write-Progress
+Write-Verbose Write-Warning
+
+----------------------------------------------------
+
+[
+	["function", "ac"],
+	["function", "cat"],
+	["function", "chdir"],
+	["function", "clc"],
+	["function", "cli"],
+	["function", "clp"],
+	["function", "clv"],
+	["function", "compare"],
+	["function", "copy"],
+	["function", "cp"],
+	["function", "cpi"],
+	["function", "cpp"],
+	["function", "cvpa"],
+	["function", "dbp"],
+	["function", "del"],
+	["function", "diff"],
+	["function", "dir"],
+	["function", "ebp"],
+	["function", "echo"],
+	["function", "epal"],
+	["function", "epcsv"],
+	["function", "epsn"],
+	["function", "erase"],
+	["function", "fc"],
+	["function", "fl"],
+	["function", "ft"],
+	["function", "fw"],
+	["function", "gal"],
+	["function", "gbp"],
+	["function", "gc"],
+	["function", "gci"],
+	["function", "gcs"],
+	["function", "gdr"],
+	["function", "gi"],
+	["function", "gl"],
+	["function", "gm"],
+	["function", "gp"],
+	["function", "gps"],
+	["function", "group"],
+	["function", "gsv"],
+	["function", "gu"],
+	["function", "gv"],
+	["function", "gwmi"],
+	["function", "iex"],
+	["function", "ii"],
+	["function", "ipal"],
+	["function", "ipcsv"],
+	["function", "ipsn"],
+	["function", "irm"],
+	["function", "iwmi"],
+	["function", "iwr"],
+	["function", "kill"],
+	["function", "lp"],
+	["function", "ls"],
+	["function", "measure"],
+	["function", "mi"],
+	["function", "mount"],
+	["function", "move"],
+	["function", "mp"],
+	["function", "mv"],
+	["function", "nal"],
+	["function", "ndr"],
+	["function", "ni"],
+	["function", "nv"],
+	["function", "ogv"],
+	["function", "popd"],
+	["function", "ps"],
+	["function", "pushd"],
+	["function", "pwd"],
+	["function", "rbp"],
+	["function", "rd"],
+	["function", "rdr"],
+	["function", "ren"],
+	["function", "ri"],
+	["function", "rm"],
+	["function", "rmdir"],
+	["function", "rni"],
+	["function", "rnp"],
+	["function", "rp"],
+	["function", "rv"],
+	["function", "rvpa"],
+	["function", "rwmi"],
+	["function", "sal"],
+	["function", "saps"],
+	["function", "sasv"],
+	["function", "sbp"],
+	["function", "sc"],
+	["function", "select"],
+	["function", "set"],
+	["function", "shcm"],
+	["function", "si"],
+	["function", "sl"],
+	["function", "sleep"],
+	["function", "sls"],
+	["function", "sort"],
+	["function", "sp"],
+	["function", "spps"],
+	["function", "spsv"],
+	["function", "start"],
+	["function", "sv"],
+	["function", "swmi"],
+	["function", "tee"],
+	["function", "trcm"],
+	["function", "type"],
+	["function", "write"],
+
+	["function", "Add-Computer"],
+	["function", "Add-Content"],
+	["function", "Add-History"],
+	["function", "Add-Member"],
+	["function", "Add-PSSnapin"],
+	["function", "Add-Type"],
+	["function", "Checkpoint-Computer"],
+	["function", "Clear-Content"],
+	["function", "Clear-EventLog"],
+	["function", "Clear-History"],
+	["function", "Clear-Item"],
+	["function", "Clear-ItemProperty"],
+	["function", "Clear-Variable"],
+	["function", "Compare-Object"],
+	["function", "Complete-Transaction"],
+	["function", "Connect-PSSession"],
+	["function", "ConvertFrom-Csv"],
+	["function", "ConvertFrom-Json"],
+	["function", "ConvertFrom-StringData"],
+	["function", "Convert-Path"],
+	["function", "ConvertTo-Csv"],
+	["function", "ConvertTo-Html"],
+	["function", "ConvertTo-Json"],
+	["function", "ConvertTo-Xml"],
+	["function", "Copy-Item"],
+	["function", "Copy-ItemProperty"],
+	["function", "Debug-Process"],
+	["function", "Disable-ComputerRestore"],
+	["function", "Disable-PSBreakpoint"],
+	["function", "Disable-PSRemoting"],
+	["function", "Disable-PSSessionConfiguration"],
+	["function", "Disconnect-PSSession"],
+	["function", "Enable-ComputerRestore"],
+	["function", "Enable-PSBreakpoint"],
+	["function", "Enable-PSRemoting"],
+	["function", "Enable-PSSessionConfiguration"],
+	["function", "Enter-PSSession"],
+	["function", "Exit-PSSession"],
+	["function", "Export-Alias"],
+	["function", "Export-Clixml"],
+	["function", "Export-Console"],
+	["function", "Export-Csv"],
+	["function", "Export-FormatData"],
+	["function", "Export-ModuleMember"],
+	["function", "Export-PSSession"],
+	["function", "ForEach-Object"],
+	["function", "Format-Custom"],
+	["function", "Format-List"],
+	["function", "Format-Table"],
+	["function", "Format-Wide"],
+	["function", "Get-Alias"],
+	["function", "Get-ChildItem"],
+	["function", "Get-Command"],
+	["function", "Get-ComputerRestorePoint"],
+	["function", "Get-Content"],
+	["function", "Get-ControlPanelItem"],
+	["function", "Get-Culture"],
+	["function", "Get-Date"],
+	["function", "Get-Event"],
+	["function", "Get-EventLog"],
+	["function", "Get-EventSubscriber"],
+	["function", "Get-FormatData"],
+	["function", "Get-Help"],
+	["function", "Get-History"],
+	["function", "Get-Host"],
+	["function", "Get-HotFix"],
+	["function", "Get-Item"],
+	["function", "Get-ItemProperty"],
+	["function", "Get-Job"],
+	["function", "Get-Location"],
+	["function", "Get-Member"],
+	["function", "Get-Module"],
+	["function", "Get-Process"],
+	["function", "Get-PSBreakpoint"],
+	["function", "Get-PSCallStack"],
+	["function", "Get-PSDrive"],
+	["function", "Get-PSProvider"],
+	["function", "Get-PSSession"],
+	["function", "Get-PSSessionConfiguration"],
+	["function", "Get-PSSnapin"],
+	["function", "Get-Random"],
+	["function", "Get-Service"],
+	["function", "Get-TraceSource"],
+	["function", "Get-Transaction"],
+	["function", "Get-TypeData"],
+	["function", "Get-UICulture"],
+	["function", "Get-Unique"],
+	["function", "Get-Variable"],
+	["function", "Get-WmiObject"],
+	["function", "Group-Object"],
+	["function", "Import-Alias"],
+	["function", "Import-Clixml"],
+	["function", "Import-Csv"],
+	["function", "Import-LocalizedData"],
+	["function", "Import-Module"],
+	["function", "Import-PSSession"],
+	["function", "Invoke-Command"],
+	["function", "Invoke-Expression"],
+	["function", "Invoke-History"],
+	["function", "Invoke-Item"],
+	["function", "Invoke-RestMethod"],
+	["function", "Invoke-WebRequest"],
+	["function", "Invoke-WmiMethod"],
+	["function", "Join-Path"],
+	["function", "Limit-EventLog"],
+	["function", "Measure-Command"],
+	["function", "Measure-Object"],
+	["function", "Move-Item"],
+	["function", "Move-ItemProperty"],
+	["function", "New-Alias"],
+	["function", "New-Event"],
+	["function", "New-EventLog"],
+	["function", "New-Item"],
+	["function", "New-ItemProperty"],
+	["function", "New-Module"],
+	["function", "New-ModuleManifest"],
+	["function", "New-Object"],
+	["function", "New-PSDrive"],
+	["function", "New-PSSession"],
+	["function", "New-PSSessionConfigurationFile"],
+	["function", "New-PSSessionOption"],
+	["function", "New-PSTransportOption"],
+	["function", "New-Service"],
+	["function", "New-TimeSpan"],
+	["function", "New-Variable"],
+	["function", "New-WebServiceProxy"],
+	["function", "Out-Default"],
+	["function", "Out-File"],
+	["function", "Out-GridView"],
+	["function", "Out-Host"],
+	["function", "Out-Null"],
+	["function", "Out-Printer"],
+	["function", "Out-String"],
+	["function", "Pop-Location"],
+	["function", "Push-Location"],
+	["function", "Read-Host"],
+	["function", "Receive-Job"],
+	["function", "Receive-PSSession"],
+	["function", "Register-EngineEvent"],
+	["function", "Register-ObjectEvent"],
+	["function", "Register-PSSessionConfiguration"],
+	["function", "Register-WmiEvent"],
+	["function", "Remove-Computer"],
+	["function", "Remove-Event"],
+	["function", "Remove-EventLog"],
+	["function", "Remove-Item"],
+	["function", "Remove-ItemProperty"],
+	["function", "Remove-Job"],
+	["function", "Remove-Module"],
+	["function", "Remove-PSBreakpoint"],
+	["function", "Remove-PSDrive"],
+	["function", "Remove-PSSession"],
+	["function", "Remove-PSSnapin"],
+	["function", "Remove-TypeData"],
+	["function", "Remove-Variable"],
+	["function", "Remove-WmiObject"],
+	["function", "Rename-Computer"],
+	["function", "Rename-Item"],
+	["function", "Rename-ItemProperty"],
+	["function", "Reset-ComputerMachinePassword"],
+	["function", "Resolve-Path"],
+	["function", "Restart-Computer"],
+	["function", "Restart-Service"],
+	["function", "Restore-Computer"],
+	["function", "Resume-Job"],
+	["function", "Resume-Service"],
+	["function", "Save-Help"],
+	["function", "Select-Object"],
+	["function", "Select-String"],
+	["function", "Select-Xml"],
+	["function", "Send-MailMessage"],
+	["function", "Set-Alias"],
+	["function", "Set-Content"],
+	["function", "Set-Date"],
+	["function", "Set-Item"],
+	["function", "Set-ItemProperty"],
+	["function", "Set-Location"],
+	["function", "Set-PSBreakpoint"],
+	["function", "Set-PSDebug"],
+	["function", "Set-PSSessionConfiguration"],
+	["function", "Set-Service"],
+	["function", "Set-StrictMode"],
+	["function", "Set-TraceSource"],
+	["function", "Set-Variable"],
+	["function", "Set-WmiInstance"],
+	["function", "Show-Command"],
+	["function", "Show-ControlPanelItem"],
+	["function", "Show-EventLog"],
+	["function", "Sort-Object"],
+	["function", "Split-Path"],
+	["function", "Start-Job"],
+	["function", "Start-Process"],
+	["function", "Start-Service"],
+	["function", "Start-Sleep"],
+	["function", "Start-Transaction"],
+	["function", "Stop-Computer"],
+	["function", "Stop-Job"],
+	["function", "Stop-Process"],
+	["function", "Stop-Service"],
+	["function", "Suspend-Job"],
+	["function", "Suspend-Service"],
+	["function", "Tee-Object"],
+	["function", "Test-ComputerSecureChannel"],
+	["function", "Test-Connection"],
+	["function", "Test-ModuleManifest"],
+	["function", "Test-Path"],
+	["function", "Test-PSSessionConfigurationFile"],
+	["function", "Trace-Command"],
+	["function", "Unblock-File"],
+	["function", "Undo-Transaction"],
+	["function", "Unregister-Event"],
+	["function", "Unregister-PSSessionConfiguration"],
+	["function", "Update-FormatData"],
+	["function", "Update-Help"],
+	["function", "Update-List"],
+	["function", "Update-TypeData"],
+	["function", "Use-Transaction"],
+	["function", "Wait-Event"],
+	["function", "Wait-Job"],
+	["function", "Wait-Process"],
+	["function", "Where-Object"],
+	["function", "Write-Debug"],
+	["function", "Write-Error"],
+	["function", "Write-EventLog"],
+	["function", "Write-Host"],
+	["function", "Write-Output"],
+	["function", "Write-Progress"],
+	["function", "Write-Verbose"],
+	["function", "Write-Warning"]
+]
+----------------------------------------------------
+
+Testing functions and aliases
\ No newline at end of file
diff --git a/tests/languages/powershell/keyword_feature.test b/tests/languages/powershell/keyword_feature.test
new file mode 100644
index 0000000..ce05886
--- /dev/null
+++ b/tests/languages/powershell/keyword_feature.test
@@ -0,0 +1,46 @@
+Begin Break Catch Class Continue Data Define Do DynamicParam Else ElseIf End
+Exit Filter Finally For ForEach From Function If InlineScript Parallel Param
+Process Return Sequence Switch Throw Trap Try Until Using Var While Workflow
+
+----------------------------------------------------
+
+[
+	["keyword", "Begin"],
+	["keyword", "Break"],
+	["keyword", "Catch"],
+	["keyword", "Class"],
+	["keyword", "Continue"],
+	["keyword", "Data"],
+	["keyword", "Define"],
+	["keyword", "Do"],
+	["keyword", "DynamicParam"],
+	["keyword", "Else"],
+	["keyword", "ElseIf"],
+	["keyword", "End"],
+	["keyword", "Exit"],
+	["keyword", "Filter"],
+	["keyword", "Finally"],
+	["keyword", "For"],
+	["keyword", "ForEach"],
+	["keyword", "From"],
+	["keyword", "Function"],
+	["keyword", "If"],
+	["keyword", "InlineScript"],
+	["keyword", "Parallel"],
+	["keyword", "Param"],
+	["keyword", "Process"],
+	["keyword", "Return"],
+	["keyword", "Sequence"],
+	["keyword", "Switch"],
+	["keyword", "Throw"],
+	["keyword", "Trap"],
+	["keyword", "Try"],
+	["keyword", "Until"],
+	["keyword", "Using"],
+	["keyword", "Var"],
+	["keyword", "While"],
+	["keyword", "Workflow"]
+]
+----------------------------------------------------
+
+Testing keywords
\ No newline at end of file
diff --git a/tests/languages/powershell/namespace_feature.test b/tests/languages/powershell/namespace_feature.test
new file mode 100644
index 0000000..92d0b94
--- /dev/null
+++ b/tests/languages/powershell/namespace_feature.test
@@ -0,0 +1,14 @@
+[System.String]::Empty;
+[Foo.Bar+Baz]::Abc;
+[int] 42;
+
+----------------------------------------------------
+
+[
+	["namespace", "[System.String]"],"::Empty",["punctuation", ";"],
+	["namespace", "[Foo.Bar+Baz]"],"::Abc",["punctuation", ";"],
+	["namespace", "[int]"]," 42",["punctuation", ";"]
+]
+----------------------------------------------------
+
+Testing namespaces
\ No newline at end of file
diff --git a/tests/languages/powershell/operator_feature.test b/tests/languages/powershell/operator_feature.test
new file mode 100644
index 0000000..cbcb25b
--- /dev/null
+++ b/tests/languages/powershell/operator_feature.test
@@ -0,0 +1,55 @@
+! -eq -ne -gt -ge -lt -le -shl -shr -not -band -and -bxor -bor -or
+-Like -Match -Contains -In -NotLike -NotMatch -NotContains -NotIn -Replace -Join
+-is -isNot -as
+-= += *= /= %= - + * / % -- ++
+
+----------------------------------------------------
+
+[
+	["operator", "!"], 
+	["operator", "-eq"], 
+	["operator", "-ne"], 
+	["operator", "-gt"], 
+	["operator", "-ge"], 
+	["operator", "-lt"], 
+	["operator", "-le"], 
+	["operator", "-shl"], 
+	["operator", "-shr"], 
+	["operator", "-not"], 
+	["operator", "-band"], 
+	["operator", "-and"], 
+	["operator", "-bxor"], 
+	["operator", "-bor"], 
+	["operator", "-or"], 
+	
+	["operator", "-Like"], 
+	["operator", "-Match"], 
+	["operator", "-Contains"], 
+	["operator", "-In"], 
+	["operator", "-NotLike"], 
+	["operator", "-NotMatch"], 
+	["operator", "-NotContains"], 
+	["operator", "-NotIn"], 
+	["operator", "-Replace"], 
+	["operator", "-Join"], 
+	["operator", "-is"], 
+	["operator", "-isNot"], 
+	["operator", "-as"], 
+	
+	["operator", "-="],
+	["operator", "+="],
+	["operator", "*="],
+	["operator", "/="],
+	["operator", "%="],
+	["operator", "-"],
+	["operator", "+"],
+	["operator", "*"],
+	["operator", "/"],
+	["operator", "%"],
+	["operator", "--"],
+	["operator", "++"]
+
+]
+----------------------------------------------------
+
+Testing operators.
\ No newline at end of file
diff --git a/tests/languages/powershell/opvarbool_feature.test b/tests/languages/powershell/opvarbool_feature.test
deleted file mode 100644
index ae84577..0000000
--- a/tests/languages/powershell/opvarbool_feature.test
+++ /dev/null
@@ -1,74 +0,0 @@
-[System.String]::Empty;
-[Foo.Bar+Baz]::Abc;
-[int] 42;
-$foo $bar_baz $var4u $1
-$true $True $false $true_as $falsey
--eq -ne -gt -ge -lt -le -shl -shr -not -band -and -bxor -bor -or
--Like -Match -Contains -In -NotLike -NotMatch -NotContains -NotIn -Replace -Join
--is -isNot -as
--= += *= /= %= - + * / % -- ++
-
-----------------------------------------------------
-
-[
-	["namespace", "[System.String]"],"::Empty",["punctuation", ";"],
-	["namespace", "[Foo.Bar+Baz]"],"::Abc",["punctuation", ";"],
-	["namespace", "[int]"]," 42",["punctuation", ";"],
-	
-	["variable", "$foo"],
-	["variable", "$bar_baz"],
-	["variable", "$var4u"],
-	["variable", "$1"],
-	
-	["boolean", "$true"],
-	["boolean", "$True"],
-	["boolean", "$false"],
-	["variable", "$true_as"],
-	["variable", "$falsey"],
-	
-	["operator", "-eq"], 
-	["operator", "-ne"], 
-	["operator", "-gt"], 
-	["operator", "-ge"], 
-	["operator", "-lt"], 
-	["operator", "-le"], 
-	["operator", "-shl"], 
-	["operator", "-shr"], 
-	["operator", "-not"], 
-	["operator", "-band"], 
-	["operator", "-and"], 
-	["operator", "-bxor"], 
-	["operator", "-bor"], 
-	["operator", "-or"], 
-	
-	["operator", "-Like"], 
-	["operator", "-Match"], 
-	["operator", "-Contains"], 
-	["operator", "-In"], 
-	["operator", "-NotLike"], 
-	["operator", "-NotMatch"], 
-	["operator", "-NotContains"], 
-	["operator", "-NotIn"], 
-	["operator", "-Replace"], 
-	["operator", "-Join"], 
-	["operator", "-is"], 
-	["operator", "-isNot"], 
-	["operator", "-as"], 
-	
-	["operator", "-="],
-	["operator", "+="],
-	["operator", "*="],
-	["operator", "/="],
-	["operator", "%="],
-	["operator", "-"],
-	["operator", "+"],
-	["operator", "*"],
-	["operator", "/"],
-	["operator", "%"],
-	["operator", "--"],
-	["operator", "++"]
-
-]
-----------------------------------------------------
-
-Testing namespaces, operators, variables and Booleans
\ No newline at end of file
diff --git a/tests/languages/powershell/variable_feature.test b/tests/languages/powershell/variable_feature.test
new file mode 100644
index 0000000..a956ea7
--- /dev/null
+++ b/tests/languages/powershell/variable_feature.test
@@ -0,0 +1,15 @@
+$foo $bar_baz $var4u $1 $true_as $falsey
+
+----------------------------------------------------
+
+[
+	["variable", "$foo"],
+	["variable", "$bar_baz"],
+	["variable", "$var4u"],
+	["variable", "$1"],
+	["variable", "$true_as"],
+	["variable", "$falsey"]
+]
+----------------------------------------------------
+
+Testing variables
\ No newline at end of file