Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The containers.EnumerateChildren test fails when there aren't any child files. #115

Open
horacioj opened this issue May 11, 2023 · 0 comments

Comments

@horacioj
Copy link

Hi,

The documentation says:

If there are no child files, this property should be an empty array.

The WOPI Host is returning:

{
  "ChildContainers": [
    {
      "Name": "some valid name 1",
      "Url": "some valid url 1"
    },
    {
      "Name": "some valid name 2",
      "Url": "some valid url 2"
    }
  ],
  "ChildFiles": []
}

However, the WOPI Validator fails with error:

Test group: EnumerateAncestorsAndChildren
  Fail: containers.EnumerateChildren
    EnumerateAncestors, response code: 200 OK
    EnumerateChildren, response code: 200 OK
      Incorrect value for 'ChildFiles[0].Name' property. Required property missing
      Incorrect value for 'ChildFiles[0].Url' property. Value is required but not provided.
      Incorrect value for 'ChildFiles[0].Version' property. Required property missing
      Incorrect value for 'ChildFiles[0].Size' property. Required property missing

I guess the same problem happens when running other tests too, because in the TestCases.xml I see many of these:

<Validators>
  <JsonResponseContentValidator>
	<StringProperty Name="ChildFiles[0].Name" IsRequired="true" />
	<AbsoluteUrlProperty Name="ChildFiles[0].Url" IsRequired="true" MustIncludeAccessToken="true" />
	<StringProperty Name="ChildFiles[0].Version" IsRequired="true" />
	<LongProperty Name="ChildFiles[0].Size" IsRequired="true" />
  </JsonResponseContentValidator>
</Validators>

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant