Fix tests

This commit is contained in:
Girish Ramakrishnan
2024-02-28 16:00:50 +01:00
parent 64bb53abc3
commit 7455490074

View File

@@ -500,7 +500,7 @@ describe('External LDAP', function () {
it('can set groups of external user when group sync is disabled', async function () {
const user = await users.getByUsername(ldapUsers[0].username);
await groups.setMembership(user, []);
await groups.setLocalMembership(user, []);
});
it('enable with groupSync', async function () {
@@ -598,12 +598,6 @@ describe('External LDAP', function () {
expect(u.username).to.equal(ldapUsers[0].username);
});
it('cannot set groups of external user when group sync is disabled', async function () {
const user = await users.getByUsername(ldapUsers[0].username);
const [error] = await safe(groups.setMembership(user, []));
expect(error.reason).to.be(BoxError.BAD_STATE);
});
it('cannot update profile of external user', async function () {
const user = await users.getByUsername(ldapUsers[0].username);
const [error] = await safe(users.updateProfile(user, { displayName: 'another name'}, auditSource));