1
0
Fork 0
liza/test
Mike Gerwitz fb88ceeae6 TokenDao: class=>interface
TokenDao has been renamed to MongoTokenDao.  While it's good for this to
have its own interface anyway, the immediate motivation was for unit tests:
I started playing with mocking with TypeScript and researching some
libraries, but I don't have time to research enough to commit to any of them
at the moment.  Interfaces remove the need to mock at all.

This also stops using `export default' in favor of just importing by
name.  Using defaults only saves us a few characters, and it makes for
awkward syntax in various cases (e.g. with multiple exports).  But I'm still
new to TS, so who knows if I'll be flip-flopping on this decision in the
future.  If we kept to our normal 1:1 file:definition convention, it
wouldn't cause problems, but based on the types I've had to define so far,
that'd cause way too much bloat and boilerplate.

* src/server/daemon/controller.js: No long import `default'.  Use
  `MongoTokenDao'.
* src/server/token/TokenedService.js: Stop checking type (since TS
  interfaces do not result in compiler output, easejs cannot validate
  against them.)
* src/server/token/MongoTokenDao.ts: Rename from `TokenDao.ts'.
* src/server/token/TokenDao.ts: Rename from `TokenQueryResult.ts'.
  (TokenDao): New interface.
* src/server/token/TokenQueryResult.ts: Rename to `TokenDao.ts'.
* test/server/token/MongoTokenDaoTest.ts: Rename from `TokenDaoTest.ts'.
2019-10-17 11:47:14 -04:00
..
bucket Copyright range update 2019-08-30 09:41:35 -04:00
calc Copyright range update 2019-08-30 09:41:35 -04:00
client Copyright range update 2019-08-30 09:41:35 -04:00
conf Add ConfLoader 2017-08-28 09:07:28 -04:00
dapi Copyright range update 2019-08-30 09:41:35 -04:00
document Copyright range update 2019-08-30 09:41:35 -04:00
event FieldVisibilityEventHandler: Fix arrow function notation 2019-10-17 11:47:14 -04:00
field Copyright range update 2019-08-30 09:41:35 -04:00
program Copyright range update 2019-08-30 09:41:35 -04:00
quote Copyright range update 2019-08-30 09:41:35 -04:00
server TokenDao: class=>interface 2019-10-17 11:47:14 -04:00
store Copyright range update 2019-08-30 09:41:35 -04:00
system Copyright range update 2019-08-30 09:41:35 -04:00
ui Copyright range update 2019-08-30 09:41:35 -04:00
validate [DEV-5657] Check for TLD in email addresses 2019-09-12 09:30:23 -04:00
pre.js Copyright range update 2019-08-30 09:41:35 -04:00