-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[chore] vcenterreceiver Updates Scraper Tests To Represent More Diver…
…se Environment (#32607) **Description:** <Describe what has changed.> No user facing changes. Updated the scraper unit tests of the vcenterreceiver to represent a more interesting environment (Multiple hosts, multiple VMs, a vApp). This will change the expected results, but will also highlight some of the odd issues that I've been noticing (and hopefully will make future PRs to fix some of these issues a little more painless). Also cleaned up the mock server and XML response files in general so they were a little easier to follow. **Link to tracking Issue:** <Issue number if applicable> N/A **Testing:** <Describe what testing was performed and which tests were added.> Unit tests passing with updated (but expected) results. **Documentation:** <Describe the documentation added.> None needed.
- Loading branch information
1 parent
27840d5
commit 17ebc7b
Showing
29 changed files
with
35,003 additions
and
145 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
17 changes: 17 additions & 0 deletions
17
receiver/vcenterreceiver/internal/mockserver/responses/cluster-resource-pool-children.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<soapenv:Envelope xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" | ||
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" | ||
xmlns:xsd="http://www.w3.org/2001/XMLSchema" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | ||
<soapenv:Body> | ||
<RetrievePropertiesResponse xmlns="urn:vim25"> | ||
<returnval> | ||
<obj type="VirtualApp">resgroup-v10</obj> | ||
<propSet> | ||
<name>name</name> | ||
<val xsi:type="xsd:string">v-app-1</val> | ||
</propSet> | ||
</returnval> | ||
</RetrievePropertiesResponse> | ||
</soapenv:Body> | ||
</soapenv:Envelope> |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
receiver/vcenterreceiver/internal/mockserver/responses/compute-datastore.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<soapenv:Envelope xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | ||
<soapenv:Body> | ||
<RetrievePropertiesResponse xmlns="urn:vim25"> | ||
<returnval> | ||
<obj type="ComputeResource">domain-c9</obj> | ||
<propSet> | ||
<name>datastore</name> | ||
<val xsi:type="ArrayOfManagedObjectReference"> | ||
<ManagedObjectReference type="Datastore" xsi:type="ManagedObjectReference">datastore-1003</ManagedObjectReference> | ||
</val> | ||
</propSet> | ||
</returnval> | ||
</RetrievePropertiesResponse> | ||
</soapenv:Body> | ||
</soapenv:Envelope> |
14 changes: 14 additions & 0 deletions
14
receiver/vcenterreceiver/internal/mockserver/responses/compute-host-name.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<soapenv:Envelope xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | ||
<soapenv:Body> | ||
<RetrievePropertiesResponse xmlns="urn:vim25"> | ||
<returnval> | ||
<obj type="HostSystem">host-1003</obj> | ||
<propSet> | ||
<name>name</name> | ||
<val xsi:type="xsd:string">esxi-111.europe-southeast1.gve.goog</val> | ||
</propSet> | ||
</returnval> | ||
</RetrievePropertiesResponse> | ||
</soapenv:Body> | ||
</soapenv:Envelope> |
Oops, something went wrong.