Skip to content

Commit

Permalink
Merge pull request lightningnetwork#898 from vapopov/hrprefix
Browse files Browse the repository at this point in the history
Wrong BOLT11 prefix in regtest
  • Loading branch information
Roasbeef authored Apr 18, 2018
2 parents 8649181 + 818eab7 commit f6e6196
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions zpay32/invoice_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -686,6 +686,30 @@ func TestNewInvoice(t *testing.T) {
valid: true,
encodedInvoice: "lnbc20m1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqhp58yjmdan79s6qqdhdzgynm4zwqd5d7xmw5fk98klysy043l2ahrqsfpp3qjmp7lwpagxun9pygexvgpjdc4jdj85fr9yq20q82gphp2nflc7jtzrcazrra7wwgzxqc8u7754cdlpfrmccae92qgzqvzq2ps8pqqqqqqpqqqqq9qqqvpeuqafqxu92d8lr6fvg0r5gv0heeeqgcrqlnm6jhphu9y00rrhy4grqszsvpcgpy9qqqqqqgqqqqq7qqzqj9n4evl6mr5aj9f58zp6fyjzup6ywn3x6sk8akg5v4tgn2q8g4fhx05wf6juaxu9760yp46454gpg5mtzgerlzezqcqvjnhjh8z3g2qqdhhwkj",
},
{
// On simnet
newInvoice: func() (*Invoice, error) {
return NewInvoice(&chaincfg.SimNetParams,
testPaymentHash, time.Unix(1496314658, 0),
Amount(testMillisat24BTC),
Description(testEmptyString),
Destination(testPubKey))
},
valid: true,
encodedInvoice: "lnsb241pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdqqnp4q0n326hr8v9zprg8gsvezcch06gfaqqhde2aj730yg0durunfhv66jdgev3gnwg0aul7unhqlqvrkp23f0negjsw8ac9f6wa8w9nvppgp3updmr5znhze6l5zneztc0alknntn0wv8fkkgvjqwp0jss66cngqcj9tj6",
},
{
// On regtest
newInvoice: func() (*Invoice, error) {
return NewInvoice(&chaincfg.RegressionNetParams,
testPaymentHash, time.Unix(1496314658, 0),
Amount(testMillisat24BTC),
Description(testEmptyString),
Destination(testPubKey))
},
valid: true,
encodedInvoice: "lnbcrt241pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdqqnp4q0n326hr8v9zprg8gsvezcch06gfaqqhde2aj730yg0durunfhv66df5c8pqjjt4z4ymmuaxfx8eh5v7hmzs3wrfas8m2sz5qz56rw2lxy8mmgm4xln0ha26qkw6u3vhu22pss2udugr9g74c3x20slpcqjgq0el4h6",
},
{
// Create a litecoin testnet invoice
newInvoice: func() (*Invoice, error) {
Expand Down

0 comments on commit f6e6196

Please sign in to comment.