public void WorkflowDto_Property_Department() { var workflow = new WorkflowDto(); var value = TestHelper.OrganizationDepartmentDto(); workflow.Department = value; Assert.IsNotNull(workflow.Department); Assert.IsInstanceOfType(workflow.Department, typeof(OrganizationDepartmentDto)); Assert.AreEqual(value, workflow.Department); }
public void JobDto_Property_Department() { // Arrange var job = new JobDto(); var value = TestHelper.OrganizationDepartmentDto(); // Act job.Department = value; // Assert Assert.IsNotNull(job.Department); Assert.IsInstanceOfType(job.Department, typeof(OrganizationDepartmentDto)); Assert.AreEqual(value, job.Department); }
public void EmployeeDto_Property_Department() { // Arrange var employee = new EmployeeDto(); var value = TestHelper.OrganizationDepartmentDto(); // Act employee.Department = value; // Assert Assert.IsNotNull(employee.Department); Assert.IsInstanceOfType(employee.Department, typeof(OrganizationDepartmentDto)); Assert.AreEqual(value, employee.Department); }
public void OrganizationDepartmentDto_Extension_AsEntity_NotNull() { var organizationDepartment = TestHelper.OrganizationDepartmentDto(); var result = organizationDepartment.AsEntity(); Assert.IsNotNull(result); Assert.IsInstanceOfType(result, typeof(OrganizationDepartment)); Assert.IsNotNull(result.Name); Assert.IsInstanceOfType(result.Name, typeof(string)); Assert.AreEqual(organizationDepartment.Name, result.Name); Assert.IsNotNull(result.Organization); Assert.IsInstanceOfType(result.Organization, typeof(Organization)); Assert.IsNotNull(result.Branch); Assert.IsInstanceOfType(result.Branch, typeof(OrganizationBranch)); Assert.IsNotNull(result.Employees); Assert.IsInstanceOfType(result.Employees, typeof(List <Employee>)); Assert.IsNotNull(result.Address); Assert.IsInstanceOfType(result.Address, typeof(Address)); Assert.IsNotNull(result.Created); Assert.IsInstanceOfType(result.Created, typeof(DateTime)); Assert.AreEqual(organizationDepartment.Created, result.Created); Assert.IsNotNull(result.CreatedBy); Assert.IsInstanceOfType(result.CreatedBy, typeof(User)); Assert.IsNotNull(result.Modified); Assert.IsInstanceOfType(result.Modified, typeof(DateTime)); Assert.AreEqual(organizationDepartment.Modified, result.Modified); Assert.IsNotNull(result.ModifiedBy); Assert.IsInstanceOfType(result.ModifiedBy, typeof(User)); Assert.IsNotNull(result.IsActive); Assert.IsInstanceOfType(result.IsActive, typeof(bool)); Assert.AreEqual(organizationDepartment.IsActive, result.IsActive); Assert.IsNotNull(result.IsDeleted); Assert.IsInstanceOfType(result.IsDeleted, typeof(bool)); Assert.AreEqual(organizationDepartment.IsDeleted, result.IsDeleted); }