Skip to content

Commit a315d61

Browse files
authored
Merge pull request #39 from it-praktyk/v1.6.0-devel
Format-Pester v1.6.0
2 parents 5f82c91 + a67b50c commit a315d61

29 files changed

+1521
-118
lines changed

Format-Pester/Format-Pester.psd1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ RootModule = 'Format-Pester.psm1'
1414
# Version number of this module.
1515
# If you are increasing ModuleVersion please change also the values of variable 'ScriptVersion' in the Format-Pester.ps1 file
1616
# Verify also translations and increase the values of msg00 fields
17-
ModuleVersion = '1.5.1'
17+
ModuleVersion = '1.6.0'
1818

1919
# ID used to uniquely identify this module
2020
GUID = 'daa609a5-1293-4f62-9467-1a120c529e87'
@@ -50,7 +50,7 @@ PowerShellVersion = '4.0'
5050
# ProcessorArchitecture = ''
5151

5252
# Modules that must be imported into the global environment prior to importing this module
53-
RequiredModules = @('pester','pscribo')
53+
RequiredModules = @('Pester','PScribo')
5454

5555
# Assemblies that must be loaded prior to importing this module
5656
# RequiredAssemblies = @()

Format-Pester/Public/Format-Pester.ps1

Lines changed: 161 additions & 102 deletions
Large diffs are not rendered by default.

Format-Pester/Public/en-US/Format-Pester.psd1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
# culture = "en-US"
1919
ConvertFrom-StringData @'
20-
msgA000 = 1.5.1
20+
msgA000 = 1.6.0
2121
msgA001 = Table of Contents
2222
msgA002 = Total Tests
2323
msgA003 = Passed Tests
@@ -42,8 +42,8 @@ ConvertFrom-StringData @'
4242
msgA020 = The test result named: '{0}' is duplicated in the ResultOrder parameter values. It will be skipped to avoid duplicating of a report section.
4343
msgA021 = The test result named: '{0}' in unrecognized and will not be included in a report.
4444
msgA022 = Documents will be exported with options:
45-
msgX001 = The parameter '{0}' is deprecated and will be removed in the further version of Format-Pester. Please use the parameters Include instead.
46-
msgX002 = The parameter Order is deprecated and will be removed in the further version of Format-Pester. Please use the parameter ResultOrder instead."
45+
msgX001 = The parameter '{0}' is deprecated and will be removed in the further version of Format-Pester. Please use the parameters '{1}' instead.
46+
# msgX002 NOT_EXISTS
4747
msgX003 = The parameter PassedFirst parameter was used but passed results are not included in the report.
4848
msgX004 = The parameter FailedFirst parameter was used but failed results are not included in the report.
4949
msgB000 = Passed

Format-Pester/Public/pl-PL/Format-Pester.psd1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
# culture="pl-PL"
1919
ConvertFrom-StringData @'
20-
msgA000=1.5.1
20+
msgA000=1.6.0
2121
msgA001=Spis treści
2222
msgA002=Testy ogółem
2323
msgA003=Testy zdane
@@ -42,8 +42,8 @@ ConvertFrom-StringData @'
4242
msgA020 = Nazwa wyniku testu: '{0}' jest powielona w wartości parametru ResultOrder. Duplikat zostanie pominięty by uniknąć powielenia sekcji dokumentu.
4343
msgA021 = Nazwa wyniku testu: '{0}' jest nierozpoznana i nie zostanie uwzględniona w dokumencie. Muszą zostać użyte angielskie nazwy wyników testów.
4444
msgA022 = Dokumenty zostaną wyeksportowane przy użyciu ustawień:
45-
msgX001 = Użycie parametru '{0}' jest niepożądane gdyż zostanie on usunięty w przyszłej wersji Format-Pester. Proszę użyć parametru Include.
46-
msgX002 = Użycie parametru Order jest niepożądane gdyż zostanie on usunięty w przyszłej wersji Format-Pester. Proszę użyć parametru ResultOrder.
45+
msgX001 = Użycie parametru '{0}' jest niepożądane gdyż zostanie on usunięty w przyszłej wersji Format-Pester. Proszę użyć parametru '{1}'.
46+
#msgX002 = NOT_EXISTS
4747
msgX003 = Został użyty parametr PassedFirst ale rezultaty zdanych testów nie są ujęte w raporcie.
4848
msgX004 = Został użyty parametr FailedFirst ale rezultaty niezdanych testów nie są ujęte w raporcie.
4949
msgB000=Zdane

README.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,23 @@
22

33
# Format-Pester
44

5-
Powershell module for documenting Pester's results.
5+
Powershell module for documenting Pester's results.
66

77
All the formatting work is done by the module [PScribo](https://github.com/iainbrighton/PScribo).
88

99
Reports are generated based on a custom PowerShell object returned by Invoke-Pester. You have to provide the parameter `PassThru` to Pester. Currently, NUnit style files generated by Pester are not supported.
1010

1111
If you can't generate report on a computer where tests are executed please save tests results piping them to `Export-Clixml`.
1212

13-
You can be interested also in the [ReportUnit](https://github.com/reportunit/reportunit) tool. It's a report generator for the test-runner family. It uses stock reports from NUnit, MsTest, xUnit, TestNG and Gallio and converts them into HTML reports with dashboards.
13+
You can be interested also in the
14+
- [ReportUnit](https://github.com/reportunit/reportunit) tool. It's a report generator for the test-runner family. It uses stock reports from NUnit, MsTest, xUnit, TestNG and Gallio and converts them into HTML reports with dashboards.
15+
- [PSTestReport](https://github.com/Xainey/PSTestReport) - it's an early example to generate a static PowerShell test report. You can read about it in the blog post ["Hitchhikers Guide to the PowerShell Module Pipeline"](https://xainey.github.io/2017/powershell-module-pipeline) by Michael Willis.
1416

1517
## Report example
1618

17-
![](./img/Format-Pester-1.5.0-part.png)
19+
![](./img/Format-Pester-1.6.0-part.png)
1820

19-
Partial screenshot for a HTML report generated by Format-Pester v. 1.5.0, PScribo v. 0.7.15.63, [the full screenshot](./img/Format-Pester-1.5.0-full.png).
21+
Partial screenshot for a HTML report generated by Format-Pester v. 1.6.0, PScribo v. 0.7.19, [the full screenshot](./img/Format-Pester-1.6.0-full.png).
2022

2123
You can find more examples [here](/examples/).
2224

@@ -49,7 +51,7 @@ Format-Pester is a PowerShell module so it has to be imported before using it -
4951

5052
This command will document the results of the Pester's tests. Documents will be stored in the current path and they will be available in 3 formats (.html,.docx and .txt).
5153

52-
## Example
54+
## Example 2
5355

5456
```PowerShell
5557
Invoke-Pester -PassThru | Export-Clixml -Path .\Test-Result.xml
@@ -74,11 +76,11 @@ You can read [online version of help](/doc/Format-Pester.md) - online help gener
7476
- Travis Plunk - [GitHub](https://github.com/TravisEz13) - [Twitter](https://twitter.com/TravisPlunk)
7577
- Wojciech Sciesinski - [GitHub](https://github.com/it-praktyk) - [Twitter](https://twitter.com/ITpraktyk)
7678

77-
7879
# [Version history](VERSIONS.md)
7980

8081
# [TODO and development plans](TODO.md)
8182

8283
# License
84+
8385
Copyright 2016-17 Erwan Quelin and the community.
8486
Licensed under [the MIT License](LICENSE)

VERSIONS.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
- Updates
5050
- Added support for Skipped, Pending, Inconclusive tests results
5151
- Parameters related to sorting of sections changed: the parameter ResultsOrder added, the parameter Order deprecated
52-
- Parameters to skipping/including sections changed: the parameter Include added, the parameter FailedOnly, Passed only deprecated
52+
- Parameters to skipping/including sections changed: the parameter Include added, the parameter FailedOnly, PassedOnly deprecated
5353
- Added support for returning refecences to created files - the PassThru parameter
5454
- the structure of translations files changed
5555
- formating of document sections updated
@@ -58,4 +58,12 @@
5858

5959
- Fix
6060
- links in a table of content corrected - #29
61-
- parameter sets for the parameter DumpPScriboObject corrected - #31
61+
- parameter sets for the parameter DumpPScriboObject corrected - #31
62+
63+
## 1.6.0 - 2017-11-25
64+
65+
- Updates
66+
- An option to add a report title added
67+
- Structure of the parameter set changed due to deprecation
68+
- Warnings about deprecated parameters added
69+
- Parameters to skipping/including sections changed: the parameters SkipTableOfContent, SkipSummary, SummaryOnly deprecated

examples/1.6.0/README.md

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
# Example files
2+
3+
Files generated using
4+
5+
- Format-Pester v. 1.6.0
6+
- Pester v. 4.1.0
7+
- PScribo v. 0.7.19.93
8+
9+
## Known issues
10+
11+
- The exception message "'ClassID' cannot be found" is displayed under formatitng to HTML document. Result files look like correctly rendered. - #36.
12+
13+
## en-US
14+
15+
### 20171125a
16+
17+
```powershell
18+
19+
$FormatPesterArguments = @{
20+
'Include' = 'All'
21+
'Format' = @('word','html','text')
22+
'Path' = '.\examples\1.6.0\en-US\'
23+
'BaseFileName' = '20171125a'
24+
'ReportTitle' = 'Results of tests - a customized report title'
25+
'GroupResultsBy' = 'Result-Describe'
26+
'Language' = 'en-us'
27+
}
28+
29+
Invoke-Pester -Path .\demo\ -Show None -PassThru | Format-Pester @FormatPesterArguments
30+
31+
```
32+
33+
### 20171125b
34+
35+
```powershell
36+
37+
$FormatPesterArguments = @{
38+
'Format' = @('word','html','text')
39+
'Path' = '.\examples\1.6.0\en-US\'
40+
'BaseFileName' = '20171125b'
41+
'ReportTitle' = 'Tests results to check'
42+
'Include' = @('Title','Failed','Inconclusive')
43+
'GroupResultsBy' = 'Result-Describe-Context'
44+
'Language' = 'en-us'
45+
}
46+
47+
Invoke-Pester -Path .\demo\ -Show None -PassThru -Tag Static | Format-Pester @FormatPesterArguments
48+
49+
```
50+
51+
### 20171125c
52+
53+
```powershell
54+
55+
$FormatPesterArguments = @{
56+
'Format' = @('word','html','text')
57+
'Path' = '.\examples\1.6.0\en-US\'
58+
'BaseFileName' = '20171125c'
59+
'Include' = 'All'
60+
'ResultsOrder' = 'Skipped','Failed','Inconclusive','Passed'
61+
'GroupResultsBy' = 'Result'
62+
'Language' = 'en-US'
63+
}
64+
65+
Invoke-Pester -Path .\demo\ -Show None -PassThru | Format-Pester @FormatPesterArguments
66+
67+
```
68+
69+
## pl-PL
70+
71+
### 20171125a
72+
73+
```powershell
74+
75+
$FormatPesterArguments = @{
76+
'Format' = @('word','html','text')
77+
'Path' = '.\examples\1.6.0\pl-PL\'
78+
'BaseFileName' = '20171125a'
79+
'Title' = 'Wyniki testów'
80+
'Include' = 'Passed','Failed','Title'
81+
'GroupResultsBy' = 'Result-Describe'
82+
'Language' = 'pl-PL'
83+
}
84+
85+
86+
Invoke-Pester -Path .\demo\ -Show None -PassThru | Format-Pester @FormatPesterArguments
87+
88+
```
89+
90+
### 20171125b
91+
92+
```powershell
93+
94+
$FormatPesterArguments = @{
95+
'Format' = @('word','html','text')
96+
'Path' = '.\examples\1.6.0\pl-PL\'
97+
'BaseFileName' = '20171125b'
98+
'Include' = @('Inconclusive','Failed')
99+
'GroupResultsBy' = 'Result-Describe-Context'
100+
'Language' = 'pl-PL'
101+
}
102+
103+
Invoke-Pester -Path .\demo\ -Show None -PassThru -Tag Static | Format-Pester @FormatPesterArguments
104+
105+
```
106+
107+
### 20171125c
108+
109+
```powershell
110+
111+
$FormatPesterArguments = @{
112+
'Format' = 'word','html','text'
113+
'Path' = '.\examples\1.6.0\pl-PL\'
114+
'BaseFileName' = '20171125c'
115+
'Title' = 'Super ważne testy'
116+
'Include' = 'All'
117+
'ResultsOrder' = 'Skipped','Failed','Inconclusive','Passed'
118+
'GroupResultsBy' = 'Result'
119+
'Language' = 'pl-PL'
120+
}
121+
122+
Invoke-Pester -Path .\demo\ -Show None -PassThru | Format-Pester @FormatPesterArguments
123+
124+
```
62.2 KB
Binary file not shown.

0 commit comments

Comments
 (0)