def test_get_master_by_dept_dict(self):
     dict_master = get_master_by_dept_dict()
     for key in dict_master:
         if key == 'claims_for_range':
             self.assertEqual(dict_master[key], 0)
         else:
             for subkey in dict_master[key]:
                 self.assertEqual(dict_master[key][subkey], 0)
 def test_get_master_by_dept_dict(self):
     dict_master = get_master_by_dept_dict()
     for key in dict_master:
         if key == 'claims_for_range':
             self.assertEqual(dict_master[key], 0)
         else:
             for subkey in dict_master[key]:
                 self.assertEqual(dict_master[key][subkey], 0)
    def test_iterate_over_employees(self):
        start = timezone.make_aware(dt.datetime(2016, 6, 3, 6, 30))
        stop = timezone.make_aware(dt.datetime(2016, 6, 3, 9, 39))
        expected_employees = ['001', '004', '006', '005', '010']
        dept_dict = get_master_by_dept_dict()
        dept_dict['claims_for_range'] = 1

        expected_dict = ManHourEdgeTestCaseClockedOutEarly.get_expected_dictionary()
        employees = get_employees(start, stop)

        self.assertTrue(compare_expect_against_query(expected_employees, employees))

        dept_dict = iterate_over_employees(dept_dict, employees, start, stop)

        print(dept_dict)
        print(expected_dict)
        self.assertEqual(expected_dict, dept_dict)
    def test_iterate_over_employees(self):
        start = timezone.make_aware(dt.datetime(2016, 6, 3, 6, 30))
        stop = timezone.make_aware(dt.datetime(2016, 6, 3, 9, 39))
        expected_employees = ['001', '004', '006', '005', '010']
        dept_dict = get_master_by_dept_dict()
        dept_dict['claims_for_range'] = 1

        expected_dict = ManHourEdgeTestCaseClockedOutEarly.get_expected_dictionary(
        )
        employees = get_employees(start, stop)

        self.assertTrue(
            compare_expect_against_query(expected_employees, employees))

        dept_dict = iterate_over_employees(dept_dict, employees, start, stop)

        print(dept_dict)
        print(expected_dict)
        self.assertEqual(expected_dict, dept_dict)