@inrupt/solid-client / acl/mock
Module: acl/mock¶
Functions¶
addMockFallbackAclTo¶
▸ addMockFallbackAclTo<T>(resource
: T): T & WithFallbackAcl
Warning
Do not use this function in production code. For use in unit tests that require a SolidDataset with a fallback ACL (Access Control List).
Initialises a new empty fallback ACL and attaches it to a given SolidDataset for use in unit tests; e.g., unit tests that call getFallbackAcl.
since
0.2.0
Type parameters:¶
Name |
Type |
---|---|
|
Parameters:¶
Name |
Type |
Description |
---|---|---|
|
T |
The Resource to mock up with new fallback ACL. |
Returns: T & WithFallbackAcl
The input Resource with an empty fallback ACL attached.
Defined in: src/acl/mock.ts:88
addMockResourceAclTo¶
▸ addMockResourceAclTo<T>(resource
: T): T & WithResourceAcl
Warning
Do not use this function in production code. For use in unit tests that require a SolidDataset with a resource ACL (Access Control List).
Initialises a new empty ACL and attaches it to a given SolidDataset for use in unit tests; e.g., unit tests that call getResourceAcl.
since
0.2.0
Type parameters:¶
Name |
Type |
---|---|
|
Parameters:¶
Name |
Type |
Description |
---|---|---|
|
T |
The Resource to mock up with a new resource ACL. |
Returns: T & WithResourceAcl
The input Resource with an empty resource ACL attached.
Defined in: src/acl/mock.ts:47