Skip to content

Instantly share code, notes, and snippets.

@philangist
Created January 31, 2017 20:35
Show Gist options
  • Save philangist/0183170aceb23e08e567b0017c1e6efc to your computer and use it in GitHub Desktop.
Save philangist/0183170aceb23e08e567b0017c1e6efc to your computer and use it in GitHub Desktop.
my $user = Adama::DB::Object::User->get_test_object(
username => $username,
password => $password,
type => 'INTERNAL',
role => 'ADMIN',
scope => 'GLOBAL',
);
# ... declare a bunch of scenarios ...
foreach my $scenario (@scenarios) {
# non IAG user can modify data_sharing_enabled
my $user = Adama::DB::Object::User->new(
id => $user_id
);
$user->type => $scenario->{type};
$user->role => $scenario->{role};
$user->scope => $scenario->{scope};
$user->save;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment