Add support for manual price entry

This commit is contained in:
2024-08-29 23:17:40 +03:00
parent 46d2c2c7ef
commit 29650a3ea4
5 changed files with 47 additions and 14 deletions

View File

@@ -0,0 +1,18 @@
//
// ManualPriceFetcher.swift
// SatsPrice
//
// Created by Terry Yiu on 8/29/24.
//
import Foundation
import BigDecimal
/// Fake price fetcher that returns a randomized price. Useful for development testing without requiring a network call.
class ManualPriceFetcher: PriceFetcher {
var price: BigDecimal = 1
func btcToUsd() async throws -> BigDecimal? {
return price
}
}