townhallproject / lawmakers-manager

0 stars 1 forks source link

Switch to Firestore #17

Closed evamaxfield closed 4 years ago

evamaxfield commented 5 years ago

Alright, the script for open states scrapping and general backend updates with firestore and office_people and etc is "complete"...

Follow the new README to create a new dev firebase and API key stuff (or just copy API keys).

A couple of notes:

  1. Tested by following the README steps to initially populate the database, then removing a single document in both the office_people collection and created a fake document with a random id and gave them the same displayName and state as before, then additionally removed that individuals associated state leg lookup document and created a fake document with a random id and gave them the same displayName and the same id as the office_people collection document created. To make this testing easier, I didn't auto generate an id but simply used the id blahblah for both the office_people fake document and the state leg lookup fake document.
  2. While I wrote a test for the checkDatabaseShortInfo function, it is failing... even though the actual database tests run.