From 3875a7a6c9178f968e7412a455721b02e05957e0 Mon Sep 17 00:00:00 2001 From: Jin Soon Lim <38507396+j5lim@users.noreply.github.com> Date: Thu, 11 Apr 2019 11:11:57 -0700 Subject: [PATCH] [Hub Generated] Review request for Microsoft.PolicyInsights to add version 2018-07-01-preview (#5408) * Fix incorrect types * Transform the type of expressionValue and targetValue to object type for the languages that support a generic object type. --- ...rceScopeExpandPolicyEvaluationDetails.json | 12 +++++------ .../policyinsights/resource-manager/readme.md | 21 +++++++++++++++++++ 2 files changed, 27 insertions(+), 6 deletions(-) diff --git a/specification/policyinsights/resource-manager/Microsoft.PolicyInsights/preview/2018-07-01-preview/examples/PolicyStates_QueryResourceScopeExpandPolicyEvaluationDetails.json b/specification/policyinsights/resource-manager/Microsoft.PolicyInsights/preview/2018-07-01-preview/examples/PolicyStates_QueryResourceScopeExpandPolicyEvaluationDetails.json index b7e3ea191a3c..f0dea990f1d9 100644 --- a/specification/policyinsights/resource-manager/Microsoft.PolicyInsights/preview/2018-07-01-preview/examples/PolicyStates_QueryResourceScopeExpandPolicyEvaluationDetails.json +++ b/specification/policyinsights/resource-manager/Microsoft.PolicyInsights/preview/2018-07-01-preview/examples/PolicyStates_QueryResourceScopeExpandPolicyEvaluationDetails.json @@ -93,12 +93,12 @@ "policyEvaluationDetails": { "evaluatedExpressions": [ { - "result": "False", - "expression": "name", - "path": "name", - "expressionValue": "myDomainName", - "targetValue": "someName", - "operator": "Equals" + "result": "True", + "expression": "tags", + "path": "tags", + "expressionValue": {}, + "targetValue": "global-opco", + "operator": "NotContainsKey" } ], "ifNotExistsDetails": { diff --git a/specification/policyinsights/resource-manager/readme.md b/specification/policyinsights/resource-manager/readme.md index 1578d675bd00..ecd30c2cd761 100644 --- a/specification/policyinsights/resource-manager/readme.md +++ b/specification/policyinsights/resource-manager/readme.md @@ -145,6 +145,13 @@ csharp: namespace: Microsoft.Azure.Management.PolicyInsights output-folder: $(csharp-sdks-folder)/PolicyInsights/Management/Management.PolicyInsights/Generated clear-output-folder: true +directive: + - from: swagger-document + where: $.definitions.ExpressionEvaluationDetails.properties.expressionValue + transform: $.type = "object" + - from: swagger-document + where: $.definitions.ExpressionEvaluationDetails.properties.targetValue + transform: $.type = "object" ``` ## Python @@ -162,6 +169,13 @@ python: namespace: azure.mgmt.policyinsights package-name: azure-mgmt-policyinsights clear-output-folder: true +directive: + - from: swagger-document + where: $.definitions.ExpressionEvaluationDetails.properties.expressionValue + transform: $.type = "object" + - from: swagger-document + where: $.definitions.ExpressionEvaluationDetails.properties.targetValue + transform: $.type = "object" ``` ``` yaml $(python) && $(python-mode) == 'update' python: @@ -190,6 +204,13 @@ namespace: com.microsoft.azure.management.policyinsights license-header: MICROSOFT_MIT_NO_CODEGEN payload-flattening-threshold: 1 output-folder: $(azure-libraries-for-java-folder)/azure-mgmt-policyinsights +directive: + - from: swagger-document + where: $.definitions.ExpressionEvaluationDetails.properties.expressionValue + transform: $.type = "object" + - from: swagger-document + where: $.definitions.ExpressionEvaluationDetails.properties.targetValue + transform: $.type = "object" ``` ### Java multi-api