Test example 9 – how to test with permissions
When implementing the customer wish, the focus is on getting the resulting new functionality working, irrespective of if you go down the test first road or not. With testing, we verify if this new functionality is working as intended. This does, however, not necessarily mean that all Business Central users will be able to operate this new functionality as this also depends on the permission sets that have been assigned to them.
As you might know, the most basic level at which we define permissions is the table data level. When introducing a new table in your extension, like the Lookup Value
table in the LookupValue extension, you also need to provide at least one permission set that defines the access to the table data. And like with any feature you provide; you should also test whether the permission set works right. How to do this that's what this test example is about.
In order to enable a user to access the data in...