update powershell default value (#380)

This commit is contained in:
William Cheng
2018-05-09 10:31:05 +08:00
committed by GitHub
parent b24df8882f
commit 4fd68f0f24
23 changed files with 107 additions and 107 deletions

View File

@@ -43,8 +43,8 @@ public class PowerShellClientCodegen extends DefaultCodegen implements CodegenCo
private String packageGuid = "{" + randomUUID().toString().toUpperCase() + "}"; private String packageGuid = "{" + randomUUID().toString().toUpperCase() + "}";
protected String sourceFolder = "src"; protected String sourceFolder = "src";
protected String packageName = "IO.Swagger"; protected String packageName = "Org.OpenAPITools";
protected String csharpClientPath = "$ScriptDir\\csharp\\SwaggerClient"; protected String csharpClientPath = "$ScriptDir\\csharp\\OpenAPIClient";
protected String apiDocPath = "docs/"; protected String apiDocPath = "docs/";
protected String modelDocPath = "docs/"; protected String modelDocPath = "docs/";
@@ -171,9 +171,9 @@ public class PowerShellClientCodegen extends DefaultCodegen implements CodegenCo
typeMapping.put("DateTime", "System.DateTime"); typeMapping.put("DateTime", "System.DateTime");
cliOptions.clear(); cliOptions.clear();
cliOptions.add(new CliOption(CodegenConstants.PACKAGE_NAME, "Client package name (e.g. io.swagger.client).").defaultValue(this.packageName)); cliOptions.add(new CliOption(CodegenConstants.PACKAGE_NAME, "Client package name (e.g. org.openapitools.client).").defaultValue(this.packageName));
cliOptions.add(new CliOption(CodegenConstants.OPTIONAL_PROJECT_GUID, "GUID for PowerShell module (e.g. a27b908d-2a20-467f-bc32-af6f3a654ac5). A random GUID will be generated by default.")); cliOptions.add(new CliOption(CodegenConstants.OPTIONAL_PROJECT_GUID, "GUID for PowerShell module (e.g. a27b908d-2a20-467f-bc32-af6f3a654ac5). A random GUID will be generated by default."));
cliOptions.add(new CliOption("csharpClientPath", "Path to the C# API client generated by Swagger Codegen, e.g. $ScriptDir\\..\\csharp\\SwaggerClient where $ScriptDir is the current directory. NOTE: you will need to generate the C# API client separately.").defaultValue(this.csharpClientPath)); cliOptions.add(new CliOption("csharpClientPath", "Path to the C# API client generated by OpenAPI Generator, e.g. $ScriptDir\\..\\csharp\\OpenAPIClient where $ScriptDir is the current directory. NOTE: you will need to generate the C# API client separately.").defaultValue(this.csharpClientPath));
} }
@@ -245,14 +245,14 @@ public class PowerShellClientCodegen extends DefaultCodegen implements CodegenCo
final String infrastructureFolder = (sourceFolder + File.separator + packageName + File.separator); final String infrastructureFolder = (sourceFolder + File.separator + packageName + File.separator);
supportingFiles.add(new SupportingFile("IO.Swagger.psm1.mustache", infrastructureFolder, packageName + ".psm1")); supportingFiles.add(new SupportingFile("Org.OpenAPITools.psm1.mustache", infrastructureFolder, packageName + ".psm1"));
// private // private
supportingFiles.add(new SupportingFile("Get-CommonParameters.ps1", infrastructureFolder + File.separator + "Private" + File.separator, "Get-CommonParameters.ps1")); supportingFiles.add(new SupportingFile("Get-CommonParameters.ps1", infrastructureFolder + File.separator + "Private" + File.separator, "Get-CommonParameters.ps1"));
supportingFiles.add(new SupportingFile("Out-DebugParameter.ps1", infrastructureFolder + File.separator + "Private" + File.separator, "Out-DebugParameter.ps1")); supportingFiles.add(new SupportingFile("Out-DebugParameter.ps1", infrastructureFolder + File.separator + "Private" + File.separator, "Out-DebugParameter.ps1"));
// en-US // en-US
supportingFiles.add(new SupportingFile("about_IO.Swagger.help.txt.mustache", infrastructureFolder + File.separator + "en-US" + File.separator + "about_" + packageName + ".help.txt")); supportingFiles.add(new SupportingFile("about_Org.OpenAPITools.help.txt.mustache", infrastructureFolder + File.separator + "en-US" + File.separator + "about_" + packageName + ".help.txt"));
} }
@@ -346,9 +346,9 @@ public class PowerShellClientCodegen extends DefaultCodegen implements CodegenCo
} }
/** /**
* returns the swagger type for the property * returns the OpenAPI type for the property
* *
* @param p Swagger property object * @param p OpenAPI property object
* @return string presentation of the type * @return string presentation of the type
**/ **/
@Override @Override

View File

@@ -54,7 +54,7 @@ $Manifest = @{
Path = "$ScriptDir\src\{{{packageName}}}\{{{packageName}}}.psd1" Path = "$ScriptDir\src\{{{packageName}}}\{{{packageName}}}.psd1"
Author = 'OpenAPI Generator Team' Author = 'OpenAPI Generator Team'
CompanyName = 'swagger.io' CompanyName = 'openapitools.org'
Description = '{{{packageName}}} - the PowerShell module for {{{appName}}}' Description = '{{{packageName}}} - the PowerShell module for {{{appName}}}'
RootModule = '{{{packageName}}}.psm1' RootModule = '{{{packageName}}}.psm1'

View File

@@ -39,25 +39,25 @@ function Get-FunctionsToExport {
$ScriptDir = Split-Path $script:MyInvocation.MyCommand.Path $ScriptDir = Split-Path $script:MyInvocation.MyCommand.Path
$ClientPath = ("$ScriptDir\..\..\petstore\csharp\SwaggerClient" | Resolve-Path).ProviderPath $ClientPath = ("$ScriptDir\..\..\petstore\csharp\SwaggerClient" | Resolve-Path).ProviderPath
$FunctionPath = 'API', 'Model' | ForEach-Object {Join-Path "$ScriptDir\src\IO.Swagger\" $_} $FunctionPath = 'API', 'Model' | ForEach-Object {Join-Path "$ScriptDir\src\Org.OpenAPITools\" $_}
$BinPath = "$ScriptDir\src\IO.Swagger\Bin" $BinPath = "$ScriptDir\src\Org.OpenAPITools\Bin"
Start-Process -FilePath "$ClientPath\build.bat" -WorkingDirectory $ClientPath -Wait -NoNewWindow Start-Process -FilePath "$ClientPath\build.bat" -WorkingDirectory $ClientPath -Wait -NoNewWindow
if (!(Test-Path "$ScriptDir\src\IO.Swagger\Bin" -PathType Container)) { if (!(Test-Path "$ScriptDir\src\Org.OpenAPITools\Bin" -PathType Container)) {
New-Item "$ScriptDir\src\IO.Swagger\Bin" -ItemType Directory > $null New-Item "$ScriptDir\src\Org.OpenAPITools\Bin" -ItemType Directory > $null
} }
Copy-Item "$ClientPath\bin\*.dll" $BinPath Copy-Item "$ClientPath\bin\*.dll" $BinPath
$Manifest = @{ $Manifest = @{
Path = "$ScriptDir\src\IO.Swagger\IO.Swagger.psd1" Path = "$ScriptDir\src\Org.OpenAPITools\Org.OpenAPITools.psd1"
Author = 'OpenAPI Generator Team' Author = 'OpenAPI Generator Team'
CompanyName = 'swagger.io' CompanyName = 'openapitools.org'
Description = 'IO.Swagger - the PowerShell module for OpenAPI Petstore' Description = 'Org.OpenAPITools - the PowerShell module for OpenAPI Petstore'
RootModule = 'IO.Swagger.psm1' RootModule = 'Org.OpenAPITools.psm1'
Guid = 'a27b908d-2a20-467f-bc32-af6f3a654ac5' # Has to be static, otherwise each new build will be considered different module Guid = 'a27b908d-2a20-467f-bc32-af6f3a654ac5' # Has to be static, otherwise each new build will be considered different module
PowerShellVersion = '3.0' PowerShellVersion = '3.0'

View File

@@ -1,4 +1,4 @@
# IO.Swagger - the PowerShell module for the OpenAPI Petstore # Org.OpenAPITools - the PowerShell module for the OpenAPI Petstore
This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
@@ -21,10 +21,10 @@ This PowerShell module is automatically generated by the [OpenAPI Generator](htt
Run the following command to generate the DLL Run the following command to generate the DLL
- [Windows] `Build.ps1` - [Windows] `Build.ps1`
Then import module from the .\src\IO.Swagger folder: Then import module from the .\src\Org.OpenAPITools folder:
```powershell ```powershell
using IO.Swagger.IO.Swagger/API; using Org.OpenAPITools.Org.OpenAPITools/API;
using IO.Swagger.Client; using Org.OpenAPITools.Client;
using IO.Swagger.IO.Swagger/Model; using Org.OpenAPITools.Org.OpenAPITools/Model;
``` ```

View File

@@ -1,29 +0,0 @@
#region Import functions
'API', 'Model', 'Private' | Get-ChildItem -Path {
Join-Path $PSScriptRoot $_
} -Filter '*.ps1' | ForEach-Object {
Write-Verbose "Importing file: $($_.BaseName)"
try {
. $_.FullName
} catch {
Write-Verbose "Can't import function!"
}
}
#endregion
#region Initialize APIs
'Creating object: IO.Swagger.Api.PetApi' | Write-Verbose
$Script:PetApi= New-Object -TypeName IO.Swagger.Api.PetApi -ArgumentList @($null)
'Creating object: IO.Swagger.Api.StoreApi' | Write-Verbose
$Script:StoreApi= New-Object -TypeName IO.Swagger.Api.StoreApi -ArgumentList @($null)
'Creating object: IO.Swagger.Api.UserApi' | Write-Verbose
$Script:UserApi= New-Object -TypeName IO.Swagger.Api.UserApi -ArgumentList @($null)
#endregion

View File

@@ -2,7 +2,7 @@ function Invoke-PetApiAddPet {
[CmdletBinding()] [CmdletBinding()]
Param ( Param (
[Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[IO.Swagger.Model.Pet] [Org.OpenAPITools.Model.Pet]
${pet} ${pet}
) )
@@ -96,7 +96,7 @@ function Invoke-PetApiUpdatePet {
[CmdletBinding()] [CmdletBinding()]
Param ( Param (
[Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[IO.Swagger.Model.Pet] [Org.OpenAPITools.Model.Pet]
${pet} ${pet}
) )

View File

@@ -52,7 +52,7 @@ function Invoke-StoreApiPlaceOrder {
[CmdletBinding()] [CmdletBinding()]
Param ( Param (
[Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[IO.Swagger.Model.Order] [Org.OpenAPITools.Model.Order]
${order} ${order}
) )

View File

@@ -2,7 +2,7 @@ function Invoke-UserApiCreateUser {
[CmdletBinding()] [CmdletBinding()]
Param ( Param (
[Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[IO.Swagger.Model.User] [Org.OpenAPITools.Model.User]
${user} ${user}
) )
@@ -20,7 +20,7 @@ function Invoke-UserApiCreateUsersWithArrayInput {
[CmdletBinding()] [CmdletBinding()]
Param ( Param (
[Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[IO.Swagger.Model.User[]] [Org.OpenAPITools.Model.User[]]
${user} ${user}
) )
@@ -38,7 +38,7 @@ function Invoke-UserApiCreateUsersWithListInput {
[CmdletBinding()] [CmdletBinding()]
Param ( Param (
[Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[IO.Swagger.Model.User[]] [Org.OpenAPITools.Model.User[]]
${user} ${user}
) )
@@ -131,7 +131,7 @@ function Invoke-UserApiUpdateUser {
[String] [String]
${username}, ${username},
[Parameter(Position = 1, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 1, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[IO.Swagger.Model.User] [Org.OpenAPITools.Model.User]
${user} ${user}
) )

View File

@@ -13,10 +13,10 @@ function New-ApiResponse {
) )
Process { Process {
'Creating object: IO.Swagger.Model.ApiResponse' | Write-Verbose 'Creating object: Org.OpenAPITools.Model.ApiResponse' | Write-Verbose
$PSBoundParameters | Out-DebugParameter | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug
New-Object -TypeName IO.Swagger.Model.ApiResponse -ArgumentList @( New-Object -TypeName Org.OpenAPITools.Model.ApiResponse -ArgumentList @(
${code}, ${code},
${type}, ${type},
${message} ${message}

View File

@@ -10,10 +10,10 @@ function New-Category {
) )
Process { Process {
'Creating object: IO.Swagger.Model.Category' | Write-Verbose 'Creating object: Org.OpenAPITools.Model.Category' | Write-Verbose
$PSBoundParameters | Out-DebugParameter | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug
New-Object -TypeName IO.Swagger.Model.Category -ArgumentList @( New-Object -TypeName Org.OpenAPITools.Model.Category -ArgumentList @(
${id}, ${id},
${name} ${name}
) )

View File

@@ -22,10 +22,10 @@ function New-Order {
) )
Process { Process {
'Creating object: IO.Swagger.Model.Order' | Write-Verbose 'Creating object: Org.OpenAPITools.Model.Order' | Write-Verbose
$PSBoundParameters | Out-DebugParameter | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug
New-Object -TypeName IO.Swagger.Model.Order -ArgumentList @( New-Object -TypeName Org.OpenAPITools.Model.Order -ArgumentList @(
${id}, ${id},
${petId}, ${petId},
${quantity}, ${quantity},

View File

@@ -5,7 +5,7 @@ function New-Pet {
[System.Nullable[Int64]] [System.Nullable[Int64]]
${id}, ${id},
[Parameter(Position = 0, ValueFromPipelineByPropertyName = $true)] [Parameter(Position = 0, ValueFromPipelineByPropertyName = $true)]
[System.Nullable[IO.Swagger.Model.Category]] [System.Nullable[Org.OpenAPITools.Model.Category]]
${category}, ${category},
[Parameter(Position = 0, ValueFromPipelineByPropertyName = $true, Mandatory = $true)] [Parameter(Position = 0, ValueFromPipelineByPropertyName = $true, Mandatory = $true)]
[String] [String]
@@ -14,7 +14,7 @@ function New-Pet {
[String[]] [String[]]
${photoUrls}, ${photoUrls},
[Parameter(Position = 0, ValueFromPipelineByPropertyName = $true)] [Parameter(Position = 0, ValueFromPipelineByPropertyName = $true)]
[System.Nullable[IO.Swagger.Model.Tag[]]] [System.Nullable[Org.OpenAPITools.Model.Tag[]]]
${tags}, ${tags},
[Parameter(Position = 0, ValueFromPipelineByPropertyName = $true)] [Parameter(Position = 0, ValueFromPipelineByPropertyName = $true)]
[String] [String]
@@ -22,10 +22,10 @@ function New-Pet {
) )
Process { Process {
'Creating object: IO.Swagger.Model.Pet' | Write-Verbose 'Creating object: Org.OpenAPITools.Model.Pet' | Write-Verbose
$PSBoundParameters | Out-DebugParameter | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug
New-Object -TypeName IO.Swagger.Model.Pet -ArgumentList @( New-Object -TypeName Org.OpenAPITools.Model.Pet -ArgumentList @(
${id}, ${id},
${category}, ${category},
${name}, ${name},

View File

@@ -10,10 +10,10 @@ function New-Tag {
) )
Process { Process {
'Creating object: IO.Swagger.Model.Tag' | Write-Verbose 'Creating object: Org.OpenAPITools.Model.Tag' | Write-Verbose
$PSBoundParameters | Out-DebugParameter | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug
New-Object -TypeName IO.Swagger.Model.Tag -ArgumentList @( New-Object -TypeName Org.OpenAPITools.Model.Tag -ArgumentList @(
${id}, ${id},
${name} ${name}
) )

View File

@@ -28,10 +28,10 @@ function New-User {
) )
Process { Process {
'Creating object: IO.Swagger.Model.User' | Write-Verbose 'Creating object: Org.OpenAPITools.Model.User' | Write-Verbose
$PSBoundParameters | Out-DebugParameter | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug
New-Object -TypeName IO.Swagger.Model.User -ArgumentList @( New-Object -TypeName Org.OpenAPITools.Model.User -ArgumentList @(
${id}, ${id},
${username}, ${username},
${firstName}, ${firstName},

View File

@@ -0,0 +1,29 @@
#region Import functions
'API', 'Model', 'Private' | Get-ChildItem -Path {
Join-Path $PSScriptRoot $_
} -Filter '*.ps1' | ForEach-Object {
Write-Verbose "Importing file: $($_.BaseName)"
try {
. $_.FullName
} catch {
Write-Verbose "Can't import function!"
}
}
#endregion
#region Initialize APIs
'Creating object: Org.OpenAPITools.Api.PetApi' | Write-Verbose
$Script:PetApi= New-Object -TypeName Org.OpenAPITools.Api.PetApi -ArgumentList @($null)
'Creating object: Org.OpenAPITools.Api.StoreApi' | Write-Verbose
$Script:StoreApi= New-Object -TypeName Org.OpenAPITools.Api.StoreApi -ArgumentList @($null)
'Creating object: Org.OpenAPITools.Api.UserApi' | Write-Verbose
$Script:UserApi= New-Object -TypeName Org.OpenAPITools.Api.UserApi -ArgumentList @($null)
#endregion

View File

@@ -1,8 +1,8 @@
PSTOPIC PSTOPIC
about_IO.Swagger about_Org.OpenAPITools
SHORT DESCRIPTION SHORT DESCRIPTION
IO.Swagger - the PowerShell module for the OpenAPI Petstore Org.OpenAPITools - the PowerShell module for the OpenAPI Petstore
LONG DESCRIPTION LONG DESCRIPTION
This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.

View File

@@ -1,11 +1,11 @@
# This file is auto-generated by Swagger Codegen (https://github.com/swagger-api/swagger-codegen) # This file is auto-generated by OpenAPI Generator (https://openapi-generator.tech)
# Please replace "TEST_VALUE" with a proper value and uncomment the code for testing the function # Please replace "TEST_VALUE" with a proper value and uncomment the code for testing the function
Describe 'IO.Swagger PetApi' { Describe 'Org.OpenAPITools PetApi' {
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiAddPet' { It 'Invoke-PetApiAddPet' {
$ret = Invoke-PetApiGetPetById -body "TEST_VALUE" $ret = Invoke-PetApiGetPetById -pet "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -13,7 +13,7 @@ Describe 'IO.Swagger PetApi' {
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiDeletePet' { It 'Invoke-PetApiDeletePet' {
$ret = Invoke-PetApiGetPetById -petId "TEST_VALUE" -apiKey "TEST_VALUE" $ret = Invoke-PetApiGetPetById -petId "TEST_VALUE" -apiKey "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -21,7 +21,7 @@ Describe 'IO.Swagger PetApi' {
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiFindPetsByStatus' { It 'Invoke-PetApiFindPetsByStatus' {
$ret = Invoke-PetApiGetPetById -status "TEST_VALUE" $ret = Invoke-PetApiGetPetById -status "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -29,7 +29,7 @@ Describe 'IO.Swagger PetApi' {
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiFindPetsByTags' { It 'Invoke-PetApiFindPetsByTags' {
$ret = Invoke-PetApiGetPetById -tags "TEST_VALUE" $ret = Invoke-PetApiGetPetById -tags "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -37,15 +37,15 @@ Describe 'IO.Swagger PetApi' {
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiGetPetById' { It 'Invoke-PetApiGetPetById' {
$ret = Invoke-PetApiGetPetById -petId "TEST_VALUE" $ret = Invoke-PetApiGetPetById -petId "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiUpdatePet' { It 'Invoke-PetApiUpdatePet' {
$ret = Invoke-PetApiGetPetById -body "TEST_VALUE" $ret = Invoke-PetApiGetPetById -pet "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -53,7 +53,7 @@ Describe 'IO.Swagger PetApi' {
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiUpdatePetWithForm' { It 'Invoke-PetApiUpdatePetWithForm' {
$ret = Invoke-PetApiGetPetById -petId "TEST_VALUE" -name "TEST_VALUE" -status "TEST_VALUE" $ret = Invoke-PetApiGetPetById -petId "TEST_VALUE" -name "TEST_VALUE" -status "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -61,7 +61,7 @@ Describe 'IO.Swagger PetApi' {
Context 'PetApi' { Context 'PetApi' {
It 'Invoke-PetApiUploadFile' { It 'Invoke-PetApiUploadFile' {
$ret = Invoke-PetApiGetPetById -petId "TEST_VALUE" -additionalMetadata "TEST_VALUE" -file "TEST_VALUE" $ret = Invoke-PetApiGetPetById -petId "TEST_VALUE" -additionalMetadata "TEST_VALUE" -file "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }

View File

@@ -1,11 +1,11 @@
# This file is auto-generated by Swagger Codegen (https://github.com/swagger-api/swagger-codegen) # This file is auto-generated by OpenAPI Generator (https://openapi-generator.tech)
# Please replace "TEST_VALUE" with a proper value and uncomment the code for testing the function # Please replace "TEST_VALUE" with a proper value and uncomment the code for testing the function
Describe 'IO.Swagger StoreApi' { Describe 'Org.OpenAPITools StoreApi' {
Context 'StoreApi' { Context 'StoreApi' {
It 'Invoke-StoreApiDeleteOrder' { It 'Invoke-StoreApiDeleteOrder' {
$ret = Invoke-PetApiGetPetById -orderId "TEST_VALUE" $ret = Invoke-PetApiGetPetById -orderId "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -13,7 +13,7 @@ Describe 'IO.Swagger StoreApi' {
Context 'StoreApi' { Context 'StoreApi' {
It 'Invoke-StoreApiGetInventory' { It 'Invoke-StoreApiGetInventory' {
$ret = Invoke-PetApiGetPetById $ret = Invoke-PetApiGetPetById
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -21,15 +21,15 @@ Describe 'IO.Swagger StoreApi' {
Context 'StoreApi' { Context 'StoreApi' {
It 'Invoke-StoreApiGetOrderById' { It 'Invoke-StoreApiGetOrderById' {
$ret = Invoke-PetApiGetPetById -orderId "TEST_VALUE" $ret = Invoke-PetApiGetPetById -orderId "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
Context 'StoreApi' { Context 'StoreApi' {
It 'Invoke-StoreApiPlaceOrder' { It 'Invoke-StoreApiPlaceOrder' {
$ret = Invoke-PetApiGetPetById -body "TEST_VALUE" $ret = Invoke-PetApiGetPetById -order "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }

View File

@@ -1,27 +1,27 @@
# This file is auto-generated by Swagger Codegen (https://github.com/swagger-api/swagger-codegen) # This file is auto-generated by OpenAPI Generator (https://openapi-generator.tech)
# Please replace "TEST_VALUE" with a proper value and uncomment the code for testing the function # Please replace "TEST_VALUE" with a proper value and uncomment the code for testing the function
Describe 'IO.Swagger UserApi' { Describe 'Org.OpenAPITools UserApi' {
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiCreateUser' { It 'Invoke-UserApiCreateUser' {
$ret = Invoke-PetApiGetPetById -body "TEST_VALUE" $ret = Invoke-PetApiGetPetById -user "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiCreateUsersWithArrayInput' { It 'Invoke-UserApiCreateUsersWithArrayInput' {
$ret = Invoke-PetApiGetPetById -body "TEST_VALUE" $ret = Invoke-PetApiGetPetById -user "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiCreateUsersWithListInput' { It 'Invoke-UserApiCreateUsersWithListInput' {
$ret = Invoke-PetApiGetPetById -body "TEST_VALUE" $ret = Invoke-PetApiGetPetById -user "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -29,7 +29,7 @@ Describe 'IO.Swagger UserApi' {
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiDeleteUser' { It 'Invoke-UserApiDeleteUser' {
$ret = Invoke-PetApiGetPetById -username "TEST_VALUE" $ret = Invoke-PetApiGetPetById -username "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -37,7 +37,7 @@ Describe 'IO.Swagger UserApi' {
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiGetUserByName' { It 'Invoke-UserApiGetUserByName' {
$ret = Invoke-PetApiGetPetById -username "TEST_VALUE" $ret = Invoke-PetApiGetPetById -username "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -45,7 +45,7 @@ Describe 'IO.Swagger UserApi' {
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiLoginUser' { It 'Invoke-UserApiLoginUser' {
$ret = Invoke-PetApiGetPetById -username "TEST_VALUE" -password "TEST_VALUE" $ret = Invoke-PetApiGetPetById -username "TEST_VALUE" -password "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
@@ -53,15 +53,15 @@ Describe 'IO.Swagger UserApi' {
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiLogoutUser' { It 'Invoke-UserApiLogoutUser' {
$ret = Invoke-PetApiGetPetById $ret = Invoke-PetApiGetPetById
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }
Context 'UserApi' { Context 'UserApi' {
It 'Invoke-UserApiUpdateUser' { It 'Invoke-UserApiUpdateUser' {
$ret = Invoke-PetApiGetPetById -username "TEST_VALUE" -body "TEST_VALUE" $ret = Invoke-PetApiGetPetById -username "TEST_VALUE" -user "TEST_VALUE"
#$ret | Should BeOfType IO.Swagger.Model.ModelNameHere #$ret | Should BeOfType Org.OpenAPITools.Model.ModelNameHere
#$ret.property | Should Be 0 #$ret.property | Should Be 0
} }
} }