Skip to content
This repository has been archived by the owner on Dec 2, 2024. It is now read-only.

Commit

Permalink
IOS-7612 Remove ass value for ICP (#798)
Browse files Browse the repository at this point in the history
Co-authored-by: Dmitry Fedorov <[email protected]>
  • Loading branch information
tureck1y and fedorov-d authored Aug 12, 2024
1 parent 39e1cf5 commit 2e210a9
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 7 deletions.
5 changes: 2 additions & 3 deletions BlockchainSdk/Common/Blockchain.swift
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public indirect enum Blockchain: Equatable, Hashable {
case joystream(curve: EllipticCurve)
case bittensor(curve: EllipticCurve)
case koinos(testnet: Bool)
case internetComputer(curve: EllipticCurve)
case internetComputer
case cyber(testnet: Bool)
case blast(testnet: Bool)

Expand Down Expand Up @@ -175,7 +175,6 @@ public indirect enum Blockchain: Equatable, Hashable {
.algorand(let curve, _),
.aptos(let curve, _),
.hedera(let curve, _),
.internetComputer(let curve),
.bittensor(let curve):
return curve
case .chia:
Expand Down Expand Up @@ -971,7 +970,7 @@ extension Blockchain: Codable {
case "joystream": self = .joystream(curve: curve)
case "bittensor": self = .bittensor(curve: curve)
case "koinos": self = .koinos(testnet: isTestnet)
case "internet-computer": self = .internetComputer(curve: curve)
case "internet-computer": self = .internetComputer
case "cyber": self = .cyber(testnet: isTestnet)
case "blast": self = .blast(testnet: isTestnet)
default:
Expand Down
2 changes: 1 addition & 1 deletion BlockchainSdk/Common/Blockchain/Blockchain+AllCases.swift
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ public extension Blockchain {
.joystream(curve: .ed25519_slip0010),
.bittensor(curve: .ed25519_slip0010),
.koinos(testnet: false),
.internetComputer(curve: .secp256k1),
.internetComputer,
.cyber(testnet: false),
.blast(testnet: false),
]
Expand Down
1 change: 0 additions & 1 deletion BlockchainSdkExample/BlockchainSdkExampleViewModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ class BlockchainSdkExampleViewModel: ObservableObject {
Blockchain.ton(curve: .ed25519, testnet: false),
Blockchain.xrp(curve: .ed25519),
Blockchain.tezos(curve: .ed25519),
Blockchain.internetComputer(curve: .secp256k1),
].map { $0.codingKey }

if let walletsData = UserDefaults.standard.data(forKey: walletsKey) {
Expand Down
2 changes: 1 addition & 1 deletion BlockchainSdkTests/Common/AddressTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1299,7 +1299,7 @@ class AddressesTests: XCTestCase {
}

func testICPAddressValidation() throws {
let addressService = WalletCoreAddressService(blockchain: .internetComputer(curve: .secp256k1))
let addressService = WalletCoreAddressService(blockchain: .internetComputer)
let expectedAddress = "270b15681e87d9d878ddfcf1aae4c3174295f2182efa0e533e9585c7fb940bdc"

XCTAssertEqual(expectedAddress, try addressService.makeAddress(from: secpDecompressedKey).value)
Expand Down
2 changes: 1 addition & 1 deletion BlockchainSdkTests/ICP/ICPTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import TangemSdk
@testable import BlockchainSdk

final class ICPTests: XCTestCase {
private let blockchain = Blockchain.internetComputer(curve: .secp256k1)
private let blockchain = Blockchain.internetComputer

private let sizeTester = TransactionSizeTesterUtility()

Expand Down

0 comments on commit 2e210a9

Please sign in to comment.