MetaPhase-Consulting/State-TalentMAP

View on GitHub
src/Components/BidTracker/BidTrackerCardContainer/__snapshots__/BidTrackerCardContainer.test.jsx.snap

Summary

Maintainability
Test Coverage
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`BidTrackerCardContainerComponent matches snapshot when priorityExists is false 1`] = `
<div
  className="bid-tracker-container"
>
  <BidTrackerCard
    acceptBid={[Function]}
    bid={
      Object {
        "approved_date": "2017-12-20",
        "closed_date": "2017-12-20",
        "create_date": "2017-12-20",
        "declined_date": "2017-12-20",
        "draft_date": "2017-12-20",
        "handshake_accepted_date": "2017-12-20",
        "handshake_declined_date": "2017-12-20",
        "handshake_offered_date": "2017-12-20",
        "id": 3,
        "in_panel_date": "2017-12-20",
        "is_priority": false,
        "position_info": Object {
          "bid_statistics": Array [
            Object {
              "at_skill": 0,
              "has_handshake_accepted": null,
              "has_handshake_offered": false,
              "id": null,
              "in_grade": 0,
              "in_grade_at_skill": 0,
              "total_bids": 0,
            },
          ],
          "bidcycle": Object {
            "name": "Demo BidCycle 2017-10-31 16:00:51.254762",
          },
          "id": 11,
          "position": Object {
            "bureau": "(AF) BUREAU OF AFRICAN AFFAIRS",
            "create_date": "2015-08-05",
            "grade": "03",
            "position_number": "10035561",
            "post": Object {
              "id": 199,
              "location": Object {
                "city": "Freetown",
                "code": "00A",
                "country": "Sierra Leone",
                "id": 103,
                "state": "",
              },
            },
            "skill": "POLITICAL AND ECONOMIC AFFAIRS (6050)",
            "title": "POLITICAL/ECONOMIC OFFICER",
            "update_date": "2017-06-08",
          },
        },
        "reviewer": Object {
          "email": "woodwardw@state.gov",
          "first_name": "Wendy",
          "is_cdo": false,
          "last_name": "Woodward",
          "phone_number": "555-555-5555",
          "username": "woodwardw",
        },
        "scheduled_panel_date": "2017-12-20",
        "status": "approved",
        "submitted_date": "2017-12-20",
        "update_date": "2017-12-20",
        "user": "rehmant",
      }
    }
    condensedView={false}
    declineBid={[Function]}
    deleteBid={[Function]}
    isCollapsible={true}
    priorityExists={false}
    readOnly={false}
    registerHandshake={[Function]}
    showBidCount={true}
    showRibbons={true}
    submitBid={[Function]}
    unregisterHandshake={[Function]}
    useCDOView={false}
    userId=""
    userProfile={
      Object {
        "bid_statistics": Array [
          Object {
            "draft": 1,
            "submitted": 1,
          },
        ],
        "cdo": Object {
          "email": "shadtrachl@state.gov",
          "first_name": "Leah",
          "initials": "LS",
          "last_name": "Shadtrach",
          "username": "shadtrachl",
        },
        "display_name": "John",
        "emp_id": "1",
        "employee_info": Object {
          "grade": "00",
          "skills": Array [
            Object {
              "code": "6218",
              "description": "CONSTRUCTION ENGINEERING",
            },
            Object {
              "code": "6211",
              "description": "COMPUTER SCIENCE",
            },
          ],
        },
        "employee_profile_url": Object {
          "external": "https://external.com",
          "internal": "https://internal.com",
        },
        "favorite_positions": Array [
          Object {
            "id": 1,
            "representation": "[00003026] OMS (COM) (Freetown, Sierra Leone)",
          },
          Object {
            "id": 4,
            "representation": "[00180000] OMS (DCM) (Addis Ababa, Ethiopia)",
          },
        ],
        "favorite_positions_pv": Array [
          Object {
            "id": 10,
          },
          Object {
            "id": 20,
          },
        ],
        "favorite_tandem_positions": Array [
          Object {
            "id": 1,
            "representation": "[00003026] OMS (COM) (Freetown, Sierra Leone)",
          },
          Object {
            "id": 4,
            "representation": "[00180000] OMS (DCM) (Addis Ababa, Ethiopia)",
          },
        ],
        "favorite_tandem_positions_pv": Array [
          Object {
            "id": 10,
          },
          Object {
            "id": 20,
          },
        ],
        "grade": "03",
        "id": 1,
        "initials": "JD",
        "is_cdo": false,
        "skills": Array [
          63,
          40,
        ],
        "user": Object {
          "email": "doej@state.gov",
          "first_name": "John",
          "initials": "JD",
          "last_name": "Doe",
          "username": "jdoe",
        },
        "user_info": Object {
          "office_address": "1234 Apple St. NW Washington, DC 20010",
          "office_phone": "202-876-5432",
        },
      }
    }
  />
</div>
`;

exports[`BidTrackerCardContainerComponent matches snapshot when priorityExists is true and bid.is_priority is false 1`] = `
<div
  className="bid-tracker-container"
>
  <IsOnStandby
    bid={
      Object {
        "approved_date": "2017-12-20",
        "closed_date": "2017-12-20",
        "create_date": "2017-12-20",
        "declined_date": "2017-12-20",
        "draft_date": "2017-12-20",
        "handshake_accepted_date": "2017-12-20",
        "handshake_declined_date": "2017-12-20",
        "handshake_offered_date": "2017-12-20",
        "id": 3,
        "in_panel_date": "2017-12-20",
        "is_priority": false,
        "position_info": Object {
          "bid_statistics": Array [
            Object {
              "at_skill": 0,
              "has_handshake_accepted": null,
              "has_handshake_offered": false,
              "id": null,
              "in_grade": 0,
              "in_grade_at_skill": 0,
              "total_bids": 0,
            },
          ],
          "bidcycle": Object {
            "name": "Demo BidCycle 2017-10-31 16:00:51.254762",
          },
          "id": 11,
          "position": Object {
            "bureau": "(AF) BUREAU OF AFRICAN AFFAIRS",
            "create_date": "2015-08-05",
            "grade": "03",
            "position_number": "10035561",
            "post": Object {
              "id": 199,
              "location": Object {
                "city": "Freetown",
                "code": "00A",
                "country": "Sierra Leone",
                "id": 103,
                "state": "",
              },
            },
            "skill": "POLITICAL AND ECONOMIC AFFAIRS (6050)",
            "title": "POLITICAL/ECONOMIC OFFICER",
            "update_date": "2017-06-08",
          },
        },
        "reviewer": Object {
          "email": "woodwardw@state.gov",
          "first_name": "Wendy",
          "is_cdo": false,
          "last_name": "Woodward",
          "phone_number": "555-555-5555",
          "username": "woodwardw",
        },
        "scheduled_panel_date": "2017-12-20",
        "status": "approved",
        "submitted_date": "2017-12-20",
        "update_date": "2017-12-20",
        "user": "rehmant",
      }
    }
    deleteBid={[Function]}
  />
</div>
`;

exports[`BidTrackerCardContainerComponent matches snapshot when priorityExists is true and bid.is_priority is true 1`] = `
<div
  className="bid-tracker-container"
>
  <IsPriority
    isApproved={true}
  >
    <BidTrackerCard
      acceptBid={[Function]}
      bid={
        Object {
          "approved_date": "2017-12-20",
          "closed_date": "2017-12-20",
          "create_date": "2017-12-20",
          "declined_date": "2017-12-20",
          "draft_date": "2017-12-20",
          "handshake_accepted_date": "2017-12-20",
          "handshake_declined_date": "2017-12-20",
          "handshake_offered_date": "2017-12-20",
          "id": 3,
          "in_panel_date": "2017-12-20",
          "is_priority": true,
          "position_info": Object {
            "bid_statistics": Array [
              Object {
                "at_skill": 0,
                "has_handshake_accepted": null,
                "has_handshake_offered": false,
                "id": null,
                "in_grade": 0,
                "in_grade_at_skill": 0,
                "total_bids": 0,
              },
            ],
            "bidcycle": Object {
              "name": "Demo BidCycle 2017-10-31 16:00:51.254762",
            },
            "id": 11,
            "position": Object {
              "bureau": "(AF) BUREAU OF AFRICAN AFFAIRS",
              "create_date": "2015-08-05",
              "grade": "03",
              "position_number": "10035561",
              "post": Object {
                "id": 199,
                "location": Object {
                  "city": "Freetown",
                  "code": "00A",
                  "country": "Sierra Leone",
                  "id": 103,
                  "state": "",
                },
              },
              "skill": "POLITICAL AND ECONOMIC AFFAIRS (6050)",
              "title": "POLITICAL/ECONOMIC OFFICER",
              "update_date": "2017-06-08",
            },
          },
          "reviewer": Object {
            "email": "woodwardw@state.gov",
            "first_name": "Wendy",
            "is_cdo": false,
            "last_name": "Woodward",
            "phone_number": "555-555-5555",
            "username": "woodwardw",
          },
          "scheduled_panel_date": "2017-12-20",
          "status": "approved",
          "submitted_date": "2017-12-20",
          "update_date": "2017-12-20",
          "user": "rehmant",
        }
      }
      condensedView={false}
      declineBid={[Function]}
      deleteBid={[Function]}
      isCollapsible={true}
      priorityExists={false}
      readOnly={false}
      registerHandshake={[Function]}
      showBidCount={false}
      showRibbons={true}
      submitBid={[Function]}
      unregisterHandshake={[Function]}
      useCDOView={false}
      userId=""
      userProfile={
        Object {
          "bid_statistics": Array [
            Object {
              "draft": 1,
              "submitted": 1,
            },
          ],
          "cdo": Object {
            "email": "shadtrachl@state.gov",
            "first_name": "Leah",
            "initials": "LS",
            "last_name": "Shadtrach",
            "username": "shadtrachl",
          },
          "display_name": "John",
          "emp_id": "1",
          "employee_info": Object {
            "grade": "00",
            "skills": Array [
              Object {
                "code": "6218",
                "description": "CONSTRUCTION ENGINEERING",
              },
              Object {
                "code": "6211",
                "description": "COMPUTER SCIENCE",
              },
            ],
          },
          "employee_profile_url": Object {
            "external": "https://external.com",
            "internal": "https://internal.com",
          },
          "favorite_positions": Array [
            Object {
              "id": 1,
              "representation": "[00003026] OMS (COM) (Freetown, Sierra Leone)",
            },
            Object {
              "id": 4,
              "representation": "[00180000] OMS (DCM) (Addis Ababa, Ethiopia)",
            },
          ],
          "favorite_positions_pv": Array [
            Object {
              "id": 10,
            },
            Object {
              "id": 20,
            },
          ],
          "favorite_tandem_positions": Array [
            Object {
              "id": 1,
              "representation": "[00003026] OMS (COM) (Freetown, Sierra Leone)",
            },
            Object {
              "id": 4,
              "representation": "[00180000] OMS (DCM) (Addis Ababa, Ethiopia)",
            },
          ],
          "favorite_tandem_positions_pv": Array [
            Object {
              "id": 10,
            },
            Object {
              "id": 20,
            },
          ],
          "grade": "03",
          "id": 1,
          "initials": "JD",
          "is_cdo": false,
          "skills": Array [
            63,
            40,
          ],
          "user": Object {
            "email": "doej@state.gov",
            "first_name": "John",
            "initials": "JD",
            "last_name": "Doe",
            "username": "jdoe",
          },
          "user_info": Object {
            "office_address": "1234 Apple St. NW Washington, DC 20010",
            "office_phone": "202-876-5432",
          },
        }
      }
    />
  </IsPriority>
</div>
`;