Exemplo n.º 1
0
        public Listener Login(string username, string password)
        {
            Listener s = repo.GetOne(username);

            if (s.Password == password)
            {
                return(s);
            }
            else
            {
                return(new Listener("", "", "", "", ""));
            }
        }
Exemplo n.º 2
0
        public void test()
        {
            RepositorySpeakers repo123 = new RepositorySpeakers();
            //repo123.Save(new Speaker("username", "password", "ion", "iancu", "*****@*****.**"));
            Speaker r = new Speaker("username", "password", "ion", "iancu", "*****@*****.**");

            Debug.Assert(repo123.GetOne("username").Username == "username");

            RepositoryReviews repo = new RepositoryReviews();

            Debug.Assert(repo.GetOne(5).IdP == 4);

            RepositoryListeners repl = new RepositoryListeners();

            Debug.Assert(repl.GetOne("BertW").Password == "wysco");


            RepositoryCommitteeMembers repcm = new RepositoryCommitteeMembers();

            Debug.Assert(repcm.GetOne("BenG").FirstName == "Gonzalez");

            RepositoryBiddings repb = new RepositoryBiddings();

            Debug.Assert(repb.GetOne("AndiP 5").Accepted == true);
        }