use of io.divide.shared.transitory.FilePermissions in project divide by HiddenStage.
the class TestUtils method getTestUser.
public static Credentials getTestUser() {
Credentials c = new Credentials("someUsername", "someEmail", "somePassword");
ServerCredentials sc = new ServerCredentials(c);
sc.setOwnerId(1);
FilePermissions fp = sc.getFilePermissions();
fp.setReadable(true, FilePermissions.Level.WORLD);
fp.setWritable(true, FilePermissions.Level.WORLD);
sc.setFilePermissions(fp);
sc.setAuthToken(AuthTokenUtils.getNewToken(KEY, sc));
sc.setRecoveryToken(AuthTokenUtils.getNewToken(KEY, sc));
return sc;
}
Aggregations