ZcashLightClientKit/Sources/ZcashLightClientKit/Block
Michal Fousek 5d2b2298b5 [#1012] Introduce dependency injection in the SDK
Closes #1012

- This is the first change for the dependency injection. This change
  adds `DIContainer` which is used to register and resolve dependencies.
- Then this change shows how `DIContainer` can be used to resolve
  dependencies. And it also shows how to mock dependencies in tests.
- Constructors of `Initializer` are changed to support mocking of
  depedendencies. But it doesn't affect public API in any way.
- Depedencies are registered in `Dependencies.setup()`. Then in the code
  `container.resolve(SomeType.self)` is called to get instance of the
  dependency.
- `ZcashTestCase` class is added. It inherits from `XCTestCase` and
  should be used for base class in tests. `ZcashTestCase` takes care of
  creation of `DIContainer` for dependencies mocking. In future we can
  maybe move there more things that are used in each test.
- Lot is missing here. Not all the code is using dependency injection.
  Tests for `DIContainer` are missing. Only `OfflineTests` work now
  (other tests can't be even compiled). It will be added in future
  changes.
2023-05-08 14:58:49 +02:00
..
DatabaseStorage [#1001] Remove PendingDb in favor of `v_transactions` and `v_tx_output` Views (#1001) 2023-05-05 14:30:47 -03:00
Download Fix error handling in BlockDownloaderImpl 2023-05-08 13:49:29 +02:00
Enhance [#361] Introduce ZcashError (#1005) 2023-04-24 18:15:20 -03:00
FetchUnspentTxOutputs [#361] Introduce ZcashError (#1005) 2023-04-24 18:15:20 -03:00
FilesystemStorage [#442] Introduce parallel downloading and scanning 2023-05-05 09:35:43 +02:00
SaplingParameters [#888] Make actor from ZcashRustBackendWelding 2023-04-11 17:51:28 +02:00
Scan [#442] Introduce parallel downloading and scanning 2023-05-05 09:35:43 +02:00
Utils [#1001] Remove PendingDb in favor of `v_transactions` and `v_tx_output` Views (#1001) 2023-05-05 14:30:47 -03:00
Validate [#361] Introduce ZcashError (#1005) 2023-04-24 18:15:20 -03:00
CompactBlockProcessor.swift [#1012] Introduce dependency injection in the SDK 2023-05-08 14:58:49 +02:00