From a49bdb3abcc6dcc69fcb6294eec4dbc96ba4078c Mon Sep 17 00:00:00 2001 From: dfinke Date: Thu, 20 Sep 2018 12:01:34 -0400 Subject: [PATCH 1/3] Added ps1 to for testing aliases --- __tests__/FunctionAlias.tests.ps1 | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 __tests__/FunctionAlias.tests.ps1 diff --git a/__tests__/FunctionAlias.tests.ps1 b/__tests__/FunctionAlias.tests.ps1 new file mode 100644 index 0000000..e69de29 From 4297d2ef82bce72d144dd159f1760b686851d8cc Mon Sep 17 00:00:00 2001 From: dfinke Date: Thu, 20 Sep 2018 12:09:19 -0400 Subject: [PATCH 2/3] Confirms the errors --- __tests__/FunctionAlias.tests.ps1 | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/__tests__/FunctionAlias.tests.ps1 b/__tests__/FunctionAlias.tests.ps1 index e69de29..b5d4382 100644 --- a/__tests__/FunctionAlias.tests.ps1 +++ b/__tests__/FunctionAlias.tests.ps1 @@ -0,0 +1,26 @@ +#Requires -Modules Pester +Import-Module $PSScriptRoot\..\ImportExcel.psd1 -Force + +Describe "Check if Function aliases exist" { + + It "Set-Column should exist" { + Get-Command Set-Column | Should Not Be $null + } + + It "Set-Row should exist" { + Get-Command Set-Row | Should Not Be $null + } + + It "Set-Format should exist" { + Get-Command Set-Format | Should Not Be $null + } + + It "Merge-MulipleSheets should exist" { + Get-Command Merge-MulipleSheets | Should Not Be $null + } + + It "New-ExcelChart should exist" { + Get-Command New-ExcelChart | Should Not Be $null + } + +} \ No newline at end of file From bdefb450958feebc006a42ef2d5f2938afe9ed0f Mon Sep 17 00:00:00 2001 From: dfinke Date: Thu, 20 Sep 2018 12:12:53 -0400 Subject: [PATCH 3/3] Remove space from Alias attribute --- Set-Column.ps1 | 2 +- Set-Row.ps1 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Set-Column.ps1 b/Set-Column.ps1 index c5fb42d..6b822d3 100644 --- a/Set-Column.ps1 +++ b/Set-Column.ps1 @@ -27,7 +27,7 @@ When given a valid URI, Set-ExcelColumn makes it a hyperlink. The column will be autosized to fit the links. #> [cmdletbinding()] - [Alias(" Set-Column")] + [Alias("Set-Column")] [OutputType([OfficeOpenXml.ExcelColumn],[String])] Param ( #If specifing the worksheet by name the ExcelPackage object which contains it needs to be passed diff --git a/Set-Row.ps1 b/Set-Row.ps1 index b290dcf..af26eb8 100644 --- a/Set-Row.ps1 +++ b/Set-Row.ps1 @@ -23,7 +23,7 @@ and given a double line border above and single line border below. #> [cmdletbinding()] - [Alias(" Set-Row")] + [Alias("Set-Row")] [OutputType([OfficeOpenXml.ExcelRow],[String])] Param ( #An Excel package object - e.g. from Export-Excel -passthru - requires a sheet name