Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update faqs.md #305

Merged
merged 1 commit into from
Sep 4, 2019
Merged

Update faqs.md #305

merged 1 commit into from
Sep 4, 2019

Conversation

drewvolz
Copy link
Member

@drewvolz drewvolz commented Sep 1, 2019

Note that weitz menu is crashing. See #304.

note that weitz menu is crashing
@drewvolz drewvolz requested a review from a team September 1, 2019 02:19
@carls-bot
Copy link

Some Jest tests failed. Take a peek?

FAIL source/views/transportation/bus/lib/__tests__/get-schedule-for-now.test.js
  ● returns the bus schedule for today

    expect(value).toMatchSnapshot()
    
    Received value does not match stored snapshot 1.
    
    - Snapshot
    + Received
    
    @@ -14,102 +14,102 @@
          "Carleton",
          "St. Olaf",
        ],
        "times": Array [
          Array [
    -       "2018-11-19T02:15:00.000Z",
    -       "2018-11-19T02:22:00.000Z",
    -       "2018-11-19T02:23:00.000Z",
    -       "2018-11-19T02:33:00.000Z",
    -       "2018-11-19T02:37:00.000Z",
    -       "2018-11-19T02:43:00.000Z",
    -       "2018-11-19T02:44:00.000Z",
    -       "2018-11-19T02:52:00.000Z",
    +       "2019-11-19T02:15:00.000Z",
    +       "2019-11-19T02:22:00.000Z",
    +       "2019-11-19T02:23:00.000Z",
    +       "2019-11-19T02:33:00.000Z",
    +       "2019-11-19T02:37:00.000Z",
    +       "2019-11-19T02:43:00.000Z",
    +       "2019-11-19T02:44:00.000Z",
    +       "2019-11-19T02:52:00.000Z",
          ],
          Array [
    -       "2018-11-19T02:55:00.000Z",
    -       "2018-11-19T03:02:00.000Z",
    -       "2018-11-19T03:03:00.000Z",
    -       "2018-11-19T03:13:00.000Z",
    -       "2018-11-19T03:17:00.000Z",
    -       "2018-11-19T03:23:00.000Z",
    -       "2018-11-19T03:24:00.000Z",
    -       "2018-11-19T03:32:00.000Z",
    +       "2019-11-19T02:55:00.000Z",
    +       "2019-11-19T03:02:00.000Z",
    +       "2019-11-19T03:03:00.000Z",
    +       "2019-11-19T03:13:00.000Z",
    +       "2019-11-19T03:17:00.000Z",
    +       "2019-11-19T03:23:00.000Z",
    +       "2019-11-19T03:24:00.000Z",
    +       "2019-11-19T03:32:00.000Z",
          ],
          Array [
    -       "2018-11-19T03:35:00.000Z",
    -       "2018-11-19T03:42:00.000Z",
    -       "2018-11-19T03:43:00.000Z",
    -       "2018-11-19T03:53:00.000Z",
    -       "2018-11-19T03:57:00.000Z",
    -       "2018-11-19T04:03:00.000Z",
    -       "2018-11-19T04:04:00.000Z",
    -       "2018-11-19T04:12:00.000Z",
    +       "2019-11-19T03:35:00.000Z",
    +       "2019-11-19T03:42:00.000Z",
    +       "2019-11-19T03:43:00.000Z",
    +       "2019-11-19T03:53:00.000Z",
    +       "2019-11-19T03:57:00.000Z",
    +       "2019-11-19T04:03:00.000Z",
    +       "2019-11-19T04:04:00.000Z",
    +       "2019-11-19T04:12:00.000Z",
          ],
        ],
        "timetable": Array [
          Object {
            "departures": Array [
    -         "2018-11-19T02:15:00.000Z",
    -         "2018-11-19T02:55:00.000Z",
    -         "2018-11-19T03:35:00.000Z",
    +         "2019-11-19T02:15:00.000Z",
    +         "2019-11-19T02:55:00.000Z",
    +         "2019-11-19T03:35:00.000Z",
            ],
            "name": "St. Olaf",
          },
          Object {
            "departures": Array [
    -         "2018-11-19T02:22:00.000Z",
    -         "2018-11-19T03:02:00.000Z",
    -         "2018-11-19T03:42:00.000Z",
    +         "2019-11-19T02:22:00.000Z",
    +         "2019-11-19T03:02:00.000Z",
    +         "2019-11-19T03:42:00.000Z",
            ],
            "name": "Carleton",
          },
          Object {
            "departures": Array [
    -         "2018-11-19T02:23:00.000Z",
    -         "2018-11-19T03:03:00.000Z",
    -         "2018-11-19T03:43:00.000Z",
    +         "2019-11-19T02:23:00.000Z",
    +         "2019-11-19T03:03:00.000Z",
    +         "2019-11-19T03:43:00.000Z",
            ],
            "name": "Food Co-op",
          },
          Object {
            "departures": Array [
    -         "2018-11-19T02:33:00.000Z",
    -         "2018-11-19T03:13:00.000Z",
    -         "2018-11-19T03:53:00.000Z",
    +         "2019-11-19T02:33:00.000Z",
    +         "2019-11-19T03:13:00.000Z",
    +         "2019-11-19T03:53:00.000Z",
            ],
            "name": "Cub/Target",
          },
          Object {
            "departures": Array [
    -         "2018-11-19T02:37:00.000Z",
    -         "2018-11-19T03:17:00.000Z",
    -         "2018-11-19T03:57:00.000Z",
    +         "2019-11-19T02:37:00.000Z",
    +         "2019-11-19T03:17:00.000Z",
    +         "2019-11-19T03:57:00.000Z",
            ],
            "name": "El Tequila",
          },
          Object {
            "departures": Array [
    -         "2018-11-19T02:43:00.000Z",
    -         "2018-11-19T03:23:00.000Z",
    -         "2018-11-19T04:03:00.000Z",
    +         "2019-11-19T02:43:00.000Z",
    +         "2019-11-19T03:23:00.000Z",
    +         "2019-11-19T04:03:00.000Z",
            ],
            "name": "Food Co-op",
          },
          Object {
            "departures": Array [
    -         "2018-11-19T02:44:00.000Z",
    -         "2018-11-19T03:24:00.000Z",
    -         "2018-11-19T04:04:00.000Z",
    +         "2019-11-19T02:44:00.000Z",
    +         "2019-11-19T03:24:00.000Z",
    +         "2019-11-19T04:04:00.000Z",
            ],
            "name": "Carleton",
          },
          Object {
            "departures": Array [
    -         "2018-11-19T02:52:00.000Z",
    -         "2018-11-19T03:32:00.000Z",
    -         "2018-11-19T04:12:00.000Z",
    +         "2019-11-19T02:52:00.000Z",
    +         "2019-11-19T03:32:00.000Z",
    +         "2019-11-19T04:12:00.000Z",
            ],
            "name": "St. Olaf",
          },
        ],
      }

      31 | })
      32 | 
    > 33 | test('returns an empty schedule if there is no schedule for today', () => {
      34 | 	// a sunday
      35 | 	let now = moment.utc('2017-11-12T13:14:00.000Z', moment.ISO_8601)
      36 | 	let input = buildBusSchedules(now)
      
      at Object.<anonymous> (source/views/transportation/bus/lib/__tests__/get-schedule-for-now.test.js:33:6)

FAIL source/views/building-hours/lib/__tests__/parse-hours.test.js
  ● handles wierd times › handles Saturday at 1:30am

    expect(received).toBe(expected) // Object.is equality
    
    Expected value to be:
      true
    Received:
      false

      56 | })
      57 | 
    > 58 | xdescribe('checks a list of schedules to see if any are open', () => {
      59 | 	const schedule = {days: ['Fr', 'Sa'], from: '10:30am', to: '2:00am'}
      60 | 
      61 | 	it('in normal, non-dst situations', () => {
      
      at Object.<anonymous> (source/views/building-hours/lib/__tests__/parse-hours.test.js:58:11)

FAIL source/views/building-hours/lib/__tests__/get-detailed-building-status.test.js
  ● returns a list of [isOpen, scheduleName, verboseStatus] tuples

    expect(value).toMatchSnapshot()
    
    Received value does not match stored snapshot 1.
    
    - Snapshot
    + Received
    
      Array [
        Object {
    -     "isActive": true,
    +     "isActive": false,
          "label": "Hours",
          "status": "10:30 AM — 2:00 AM",
        },
      ]

      32 | })
      33 | 
    > 34 | it('checks a list of schedules to see if any are open', () => {
      35 | 	let m = plainMoment('06-23-2018 1:00pm', 'MM-DD-YYYY h:mma')
      36 | 	let building = {
      37 | 		name: 'building',
      
      at Object.<anonymous> (source/views/building-hours/lib/__tests__/get-detailed-building-status.test.js:34:4)

  ● checks a list of schedules to see if any are open

    expect(value).toMatchSnapshot()
    
    Received value does not match stored snapshot 1.
    
    - Snapshot
    + Received
    
      Array [
        Object {
    -     "isActive": true,
    +     "isActive": false,
          "label": "Hours",
          "status": "10:30 AM — 2:00 AM",
        },
      ]

      53 | 	expect(actual).toMatchSnapshot()
      54 | 
    > 55 | 	expect(actual[0].isActive).toBe(true)
      56 | })
      57 | 
      58 | it('handles multiple internal schedules for the same timeframe', () => {
      
      at Object.<anonymous> (source/views/building-hours/lib/__tests__/get-detailed-building-status.test.js:55:9)

  ● handles multiple internal schedules for the same timeframe

    expect(value).toMatchSnapshot()
    
    Received value does not match stored snapshot 1.
    
    - Snapshot
    + Received
    
    @@ -3,10 +3,10 @@
          "isActive": false,
          "label": "Hours",
          "status": "10:30 AM — Noon",
        },
        Object {
    -     "isActive": true,
    +     "isActive": false,
          "label": "Hours",
          "status": "1:00 PM — 3:00 PM",
        },
      ]

      76 | 	expect(actual).toMatchSnapshot()
      77 | 
    > 78 | 	expect(actual[0].isActive).toBe(false)
      79 | 	expect(actual[1].isActive).toBe(true)
      80 | })
      81 | 
      
      at Object.<anonymous> (source/views/building-hours/lib/__tests__/get-detailed-building-status.test.js:78:9)

  ● handles multiple named schedules for the same timeframe

    expect(value).toMatchSnapshot()
    
    Received value does not match stored snapshot 1.
    
    - Snapshot
    + Received
    
    @@ -8,10 +8,10 @@
          "isActive": false,
          "label": "Hours2",
          "status": "10:30 AM — Noon",
        },
        Object {
    -     "isActive": true,
    +     "isActive": false,
          "label": "Hours2",
          "status": "1:00 PM — 3:00 PM",
        },
      ]

      104 | 	expect(actual).toMatchSnapshot()
      105 | 
    > 106 | 	expect(actual[0].isActive).toBe(false)
      107 | 	expect(actual[1].isActive).toBe(false)
      108 | 	expect(actual[2].isActive).toBe(true)
      109 | })
      
      at Object.<anonymous> (source/views/building-hours/lib/__tests__/get-detailed-building-status.test.js:106:9)


Snapshot Summary
 › 5 snapshot tests failed in 2 test suites. Inspect your code changes or run `yarn test -u` to update them.

Test Suites: 3 failed, 1 skipped, 23 passed, 26 of 27 total
Tests:       6 failed, 9 skipped, 131 passed, 146 total
Snapshots:   5 failed, 24 passed, 29 total

Generated by 🚫 dangerJS

@drewvolz
Copy link
Member Author

drewvolz commented Sep 2, 2019

@hawkrives I'm going to merge this within a day unless you object.

@drewvolz drewvolz merged commit f085839 into master Sep 4, 2019
@drewvolz drewvolz deleted the update-faqs branch September 4, 2019 23:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants