List Bitzec (BZC)

This commit is contained in:
sennevb 2018-12-29 14:54:06 +01:00 committed by Bernard Labno
parent f8f9492b3e
commit 6d3328dba2
No known key found for this signature in database
GPG key ID: FB792CBD872450F0
3 changed files with 73 additions and 0 deletions

View file

@ -0,0 +1,29 @@
/*
* This file is part of Bisq.
*
* Bisq is free software: you can redistribute it and/or modify it
* under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at
* your option) any later version.
*
* Bisq is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
* License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Bisq. If not, see <http://www.gnu.org/licenses/>.
*/
package bisq.asset.coins;
import bisq.asset.Coin;
import bisq.asset.RegexAddressValidator;
public class Bitzec extends Coin {
public Bitzec() {
super("Bitzec", "BZC", new RegexAddressValidator("^t.*", "validation.altcoin.zAddressesNotSupported"));
}
}

View file

@ -14,6 +14,7 @@ bisq.asset.coins.BitcoinRhodium
bisq.asset.coins.Bitcoin$Testnet
bisq.asset.coins.BitDaric
bisq.asset.coins.Bitmark
bisq.asset.coins.Bitzec
bisq.asset.coins.Blur
bisq.asset.coins.BSQ$Mainnet
bisq.asset.coins.BSQ$Regtest

View file

@ -0,0 +1,43 @@
/*
* This file is part of Bisq.
*
* Bisq is free software: you can redistribute it and/or modify it
* under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at
* your option) any later version.
*
* Bisq is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
* License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Bisq. If not, see <http://www.gnu.org/licenses/>.
*/
package bisq.asset.coins;
import bisq.asset.AbstractAssetTest;
import org.junit.Test;
public class BitzecTest extends AbstractAssetTest {
public BitzecTest() {
super(new Bitzec());
}
@Test
public void testValidAddresses() {
assertValidAddress("t1K6LGT7z2uNTLxag6eK6XwGNpdkHbncBaK");
assertValidAddress("t1ZjdqCGEkqL9nZ8fk9R6KA7bqNvXaVLUpF");
}
@Test
public void testInvalidAddresses() {
assertInvalidAddress("17VZNX1SN5NtKa8UQFxwQbFeFc3iqRYhem");
assertInvalidAddress("38NwrYsD1HxQW5zfLT0QcUUXGMPvQgzTSn");
assertInvalidAddress("8tP9rh3SH6n9cSLmV22vnSNNw56LKGpLrB");
assertInvalidAddress("8Zbvjr");
}
}