Changeset 3389960 in flexoentity for tests/test_composite_backend.py


Ignore:
Timestamp:
02/27/26 13:47:23 (3 days ago)
Author:
Enrico Schwass <ennoausberlin@…>
Branches:
unify_backends
Children:
c1144fd
Parents:
54941b4
Message:

redesign of Identity and PersistanceBackends - this is a breaking change.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/test_composite_backend.py

    r54941b4 r3389960  
    1010    backend = CompositeBackend(authoritative_backend=primary, sync_backends=[secondary])
    1111
    12     backend.save(sample_domain)
     12    backend.save(sample_domain.to_dict())
    1313
    1414    fid = sample_domain.flexo_id
     
    2525    backend = CompositeBackend(authoritative_backend=primary, sync_backends=[secondary])
    2626
    27     primary.save(sample_domain)
     27    primary.save(sample_domain.to_dict())
    2828
    2929    # secondary has nothing, but composite should still load from primary
    3030    fid = sample_domain.flexo_id
    31     loaded = backend.load(fid)
     31    loaded = Domain.from_dict(backend.load(fid))
    3232    assert isinstance(loaded, Domain)
    3333
     
    3939    backend = CompositeBackend(authoritative_backend=primary, sync_backends=[secondary])
    4040
    41     backend.save(sample_domain)
     41    backend.save(sample_domain.to_dict())
    4242
    4343    backend.clear()
Note: See TracChangeset for help on using the changeset viewer.