Archived entries from file /Users/zyoung/TimeTracker/todo.org
Returns dt for next payday, has to know some previous payday to calculate every second week, or maybe just `if now::week_num % 2` because we started invoicing at the end of week 1 in the new year.Archived entries from file /Users/zyoung/TimeTracker/todo.org
This should open note.txt, parse it, and print out an invoice Mcelhose –> mcel, McElhose –> mcel Write invoice and invoiced entries to an invoice file Right now it’s written around ConfigParser which is disk-specific IO. I think it can be rewritten around a dictionary; and so the caller picks their data layer and passes it off as a dictionary. For now, tests and generating invoices for Ken and FF, the data layer will be disk. Invoice will be for last week (few hours) and this week (zero hours), pay period is 2/4 - 2/17 There are self-referential asserts intestWriteInvoice()
that
don’t really prove anything. This became apparent when changing
self.net_30
to None
in all the Invoice()
instantiators.
There’s a lot of date-time precision that’s kept in the written
file that might be making testing harder.
Removed a lot of junk in testWriteInvoice()
that had nothing to
do with the test, which is just verifying that a file was written.
All the exact-value assertions (especially dates and computed
values) belong in other methods: testSendInvoice()
and
testPrintInvoicedEntries()
.
Finney Farm’s invoice was named with the 2-week convention that works for Ken’s invoicing. Maybe call this ‘invoicingperiod’. “every 2 weeks starting on Monday”… is waaay awesome, but also waaayyy beyond me and this program at this point. Simply defining the period per company is fine for now.