Beispiel #1
0
 public Managment(string email)
 {
     InitializeComponent();
     //cbDepart.DataSource = Enum.GetValues(typeof(Department));
     managment          = new BazaarManagment();
     ProductManagment   = new ProductManagement();
     conn               = new ConnectionClass();
     this.current_email = email;
 }
Beispiel #2
0
        public void AddNewEmployeeTest()
        {
            BazaarManagment bm = new BazaarManagment();

            bm.AddNewEmployee("John", "Doe", Gender.MALE, Position.EMPLOYEE, Department.DEPOT, DateTime.Today, "Netherlands", "Eindhoven", "5612JC", "JohannesWaalsweg", "*****@*****.**", "Dutch", "Dutch", 123, DateTime.Today, 40);
            bm.AddNewEmployee("Jane", "Doe", Gender.FEMALE, Position.MANAGER, Department.HUMANRESOURCES, DateTime.Today, "Netherlandsa", "Eindhovena", "5612JaC", "JohannesWaalswega", "*****@*****.**", "Dutch", "Dutch", 1234, DateTime.Today, 43);
            Employee e  = new Employee("John", "Doe", Gender.MALE, Position.EMPLOYEE, Department.DEPOT, DateTime.Today, "Netherlands", "Eindhoven", "5612JC", "JohannesWaalsweg", "*****@*****.**", "Dutch", "Dutch", 123, DateTime.Today, 40);
            Employee em = new Employee("Jane", "Doe", Gender.FEMALE, Position.MANAGER, Department.HUMANRESOURCES, DateTime.Today, "Netherlandsa", "Eindhovena", "5612JaC", "JohannesWaalswega", "*****@*****.**", "Dutch", "Dutch", 1234, DateTime.Today, 43);

            CollectionAssert.AreEquivalent(new Employee[] { e, em }, bm.newEmployeesList);
        }