Skip to content

Commit

Permalink
chore: add test to cover not sending empty array when other has data (#…
Browse files Browse the repository at this point in the history
…44)

## Description

Adds the `Deletes` property to the test to ensure that we don't pass
this when it is empty. Given that we don't match on body this isn't
really much gain but it will help to ensure we maintain this in future
if we improve testing.

## References

Part of openfga/sdk-generator#299
Generated from openfga/sdk-generator#306

## Review Checklist
- [x] I have clicked on ["allow edits by
maintainers"](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork).
- [ ] I have added documentation for new/changed functionality in this
PR or in a PR to [openfga.dev](https://github.com/openfga/openfga.dev)
[Provide a link to any relevant PRs in the references section above]
- [x] The correct base branch is being used, if not `main`
- [ ] I have added tests to validate that the change in functionality is
working as expected
  • Loading branch information
rhamzeh authored Feb 12, 2024
2 parents cf1bdc6 + 14218b7 commit 6fdff8b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/OpenFga.Sdk.Test/Client/OpenFgaClientTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -805,6 +805,7 @@ public async Task WriteWriteTest() {
Object = "document:roadmap",
}
},
Deletes = new List<ClientTupleKeyWithoutCondition>(), // should not get passed
};
var response = await fgaClient.Write(body, new ClientWriteOptions {
AuthorizationModelId = "01GXSA8YR785C4FYS3C0RTG7B1",
Expand Down

0 comments on commit 6fdff8b

Please sign in to comment.