Skip to content

Commit

Permalink
[Windows] Adding Swig (actions#3509)
Browse files Browse the repository at this point in the history
  • Loading branch information
kassannk authored Jun 7, 2021
1 parent 46ced60 commit 659b9d8
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 3 deletions.
8 changes: 8 additions & 0 deletions images/win/scripts/Installers/Install-Swig.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
################################################################################
## File: Install-Swig.ps1
## Desc: Install Swig
################################################################################

Choco-Install -PackageName swig

Invoke-PesterTests -TestFile "Tools" -TestName "Swig"
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ $markdown += New-MDList -Style Unordered -Lines (@(
(Get-StackVersion),
(Get-SVNVersion),
(Get-VSWhereVersion),
(Get-SwigVersion),
(Get-WinAppDriver),
(Get-ZstdVersion),
(Get-YAMLLintVersion)
Expand Down
8 changes: 7 additions & 1 deletion images/win/scripts/SoftwareReport/SoftwareReport.Tools.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -257,4 +257,10 @@ function Get-DacFxVersion {
cd "C:\Program Files\Microsoft SQL Server\150\DAC\bin\"
$dacfxversion = (./sqlpackage.exe /version)
return "DacFx $dacfxversion"
}
}

function Get-SwigVersion {
(swig -version | Out-String) -match "version (?<version>\d+\.\d+\.\d+)" | Out-Null
$swigVersion = $Matches.Version
return "Swig $swigVersion"
}
6 changes: 6 additions & 0 deletions images/win/scripts/Tests/Tools.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -258,3 +258,9 @@ Describe "Pipx" {
"pipx --version" | Should -ReturnZeroExitCode
}
}

Describe "Swig" {
It "Swig" {
"swig -version" | Should -ReturnZeroExitCode
}
}
3 changes: 2 additions & 1 deletion images/win/windows2016.json
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,8 @@
"{{ template_dir }}/scripts/Installers/Install-Selenium.ps1",
"{{ template_dir }}/scripts/Installers/Install-IEWebDriver.ps1",
"{{ template_dir }}/scripts/Installers/Install-Apache.ps1",
"{{ template_dir }}/scripts/Installers/Install-Nginx.ps1"
"{{ template_dir }}/scripts/Installers/Install-Nginx.ps1",
"{{ template_dir }}/scripts/Installers/Install-Swig.ps1"
]
},
{
Expand Down
3 changes: 2 additions & 1 deletion images/win/windows2019.json
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,8 @@
"{{ template_dir }}/scripts/Installers/Install-Selenium.ps1",
"{{ template_dir }}/scripts/Installers/Install-IEWebDriver.ps1",
"{{ template_dir }}/scripts/Installers/Install-Apache.ps1",
"{{ template_dir }}/scripts/Installers/Install-Nginx.ps1"
"{{ template_dir }}/scripts/Installers/Install-Nginx.ps1",
"{{ template_dir }}/scripts/Installers/Install-Swig.ps1"
]
},
{
Expand Down

0 comments on commit 659b9d8

Please sign in to comment.