private static JToken GetTokenAs(Role role)
        {
            var users       = JsonDataHelper.ToObject <List <User> >("Configuration\\credentials.json");
            var testUser    = users.Where(user => user.Role == role.ToString()).SingleOrDefault();
            var tokenObject = IdentityAPI.GetToken(testUser.Email, testUser.Password);

            return(tokenObject);
        }
Exemple #2
0
        public void AddNewSkill()
        {
            IdentityAPI.SigninAs(Role.talent);
            ProfilePage.Open();
            var skill = new Skill();

            ProfilePage.Skills.AddNewSkill(skill);
            Assert.IsTrue(ProfilePage.Skills.IsAdded(skill));
        }
Exemple #3
0
        public void DeleteSkill()
        {
            IdentityAPI.SigninAs(Role.talent);
            var skill = new Skill();

            TalentAPI.PostSkill(skill);
            ProfilePage.Open();
            ProfilePage.Skills.DeleteSkill(skill);
            Assert.IsTrue(ProfilePage.Skills.IsDeleted(skill));
        }