Anki/tests
Damien Elmes 0c9672e7b8 rewrite media support
- media is no longer hashed, and instead stored in the db using its original
  name
- when adding media, its checksum is calculated and used to look for
  duplicates
- duplicate filenames will result in a number tacked on the file
- the size column is used to count card references to media. If media is
  referenced in a fact but not the question or answer, the count will be zero.
- there is no guarantee media will be listed in the media db if it is unused
  on the question & answer
- if rebuildMediaDir(delete=True), then entries with zero references are
  deleted, along with any unused files in the media dir.
- rebuildMediaDir() will update the internal checksums, and set the checksum
  to "" if a file can't be found
- rebuildMediaDir() is a lot less destructive now, and will leave alone
  directories it finds in the media folder (but not look in them either)
- rebuildMediaDir() returns more information about the state of media now
- the online and mobile clients will need to to make sure that when
  downloading media, entries with no checksum are non-fatal and should not
  abort the download process.
- the ref count is updated every time the q/a is updated - so the db should be
  up to date after every add/edit/import
- since we look for media on the q/a now, card templates like '<img
  src="{{{field}}}">' will work now
- export original files as gone as it is not needed anymore
- move from per-model media URL to deckVar. downloadMissingMedia() uses this
  now. Deck subscriptions will have to be updated to share media another way.
- pass deck in formatQA, as latex support is going to change
2010-12-11 01:19:31 +09:00
..
deck support media for memory backed files 2009-01-04 07:40:32 +09:00
importing add ability to update fields when importing 2010-11-26 01:36:24 +09:00
syncing/media-tests initial commit from hg 2008-09-27 23:50:03 +09:00
__init__.py initial commit from hg 2008-09-27 23:50:03 +09:00
shared.py initial commit from hg 2008-09-27 23:50:03 +09:00
test_deck.py Require explicit reset for most queue-modifying functions 2010-11-23 17:41:36 +09:00
test_exporting.py don't backup in unit tests 2010-02-20 10:03:47 +09:00
test_importing.py add ability to update fields when importing 2010-11-26 01:36:24 +09:00
test_media.py rewrite media support 2010-12-11 01:19:31 +09:00
test_sync.py rewrite media support 2010-12-11 01:19:31 +09:00
test_utils.py do need to rebuild counts on export 2008-11-21 15:46:17 +09:00