Add node location access RPCs and operator visibility
This commit is contained in:
@@ -177,5 +177,14 @@ describe('authorizeNodeMethod', () => {
|
||||
roleScopes: { companion: ['node.capabilities.get'] },
|
||||
});
|
||||
expect(allowed.authenticated).toBe(true);
|
||||
|
||||
const allowedLocation = authorizeNodeMethod({
|
||||
enabled: true,
|
||||
method: 'node.location.set',
|
||||
nodeRole: 'companion',
|
||||
allowedRoles: ['companion'],
|
||||
roleScopes: { companion: ['node.capabilities.get', 'node.location.set'] },
|
||||
});
|
||||
expect(allowedLocation.authenticated).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user