Skip to content

[BUG] fields.info not camelCase #3243

@xarem

Description

@xarem

Describe the bug

Similar to #3241

fields.info is still PascalCase

To Reproduce

vcsim -api-version 8.0 -dc 0 -l :8989 &
export GOVC_URL=https://user:pass@172.17.0.2:8989/sdk GOVC_SIM_PID=10
export GOVC_INSECURE=true

govc fields.add -type=Folder folder-test
govc datacenter.create test-dc
govc cluster.create test-cluster
govc cluster.add -hostname test-host -username user -password pass -noverify
govc datastore.create -type local -name test-ds -path /tmp 'test-cluster/*'
govc vm.create -net="VM Network" -m=4096 -c=1 -g=ubuntu -disk=40G -folder=/test-dc/vm test-vm
govc fields.set folder-test "Hello world" /test-dc/vm/test-vm
govc fields.info -json /test-dc/vm/test-vm

Result

{
  "Info": [
    {
      "Object": {
        "type": "VirtualMachine",
        "value": "vm-22"
      },
      "Path": "/test-dc/vm/test-vm",
      "Name": "test-vm",
      "Key": "folder-test",
      "Value": "Hello world"
    }
  ]
}

Expected behavior

{
  "info": [
    {
      "object": {
        "type": "VirtualMachine",
        "value": "vm-22"
      },
      "path": "/test-dc/vm/test-vm",
      "name": "test-vm",
      "key": "folder-test",
      "value": "Hello world"
    }
  ]
}

Affected version

v0.31.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions