Closes#1315
This PR introduces small changes on each commit.
Things done:
rename Checkpoint+Constants to Checkpoint+helpers
Move `Checkpoint` from Model folder to Checkpoint folder
Remove unused function `ofLatestCheckpoint` from BlockHeight
Create a protocol called `CheckpointSource` that contains the
relevant functionality to get checkpoints from Bundle
Create a set of tests that check that functionality is maintained
when a `CheckpointSource` is used instead of Checkpoint helpers
Implement `BundleCheckpointSource` and add Tests
Code clean up: move `BundleCheckpointURLProvider` to its own file
Code clean up: `Checkpoint+helpers` match file header
Replace use of `Checkpoint.birthday(with:network)` with CheckpointSource
Revert "Remove unused function `ofLatestCheckpoint` from BlockHeight"
addresses PR comment from @daira
This reverts commit d0e154ded7, since it
modifies a public API and it was not the goal of this PR.
Update Sources/ZcashLightClientKit/Checkpoint/BundleCheckpointSource.swift
Use a decent Date Format
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
Improve documentation on BundleCheckpointURLProvider
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
Improve documentation on BundleCheckpointURLProvider
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
use YYYY-mm-dd on file header
author: @daira
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
Add test that verifies that the exact height is returned if available