Repository: kaspanet/kaspad
Pull request #1683 (2021-04-20 11:21:55)

Update the testnet version to testnet-5

codecov[bot]: # [Codecov](https://codecov.io/gh/kaspanet/kaspad/pull/1683?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet) Report
> Merging [#1683](https://codecov.io/gh/kaspanet/kaspad/pull/1683?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet) (c26372c) into [v0.10.0-dev](https://codecov.io/gh/kaspanet/kaspad/commit/dfd8b3423d8d76e440831ce152b864af3e3c951e?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet) (dfd8b34) will **decrease** coverage by `0.00%`.
> The diff coverage is `n/a`.

> :exclamation: Current head c26372c differs from pull request most recent head 3339c23. Consider uploading reports for the commit 3339c23 to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/kaspanet/kaspad/pull/1683/graphs/tree.svg?width=650&height=150&src=pr&token=2FBIEEJTNU&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet)](https://codecov.io/gh/kaspanet/kaspad/pull/1683?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet)

```diff
@@               Coverage Diff               @@
##           v0.10.0-dev    #1683      +/-   ##
===============================================
- Coverage        59.44%   59.43%   -0.01%     
===============================================
  Files              551      551              
  Lines            21930    21930              
===============================================
- Hits             13036    13034       -2     
- Misses            6818     6820       +2     
  Partials          2076     2076              
```


| [Impacted Files](https://codecov.io/gh/kaspanet/kaspad/pull/1683?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet) | Coverage Δ | |
|---|---|---|
| [domain/dagconfig/params.go](https://codecov.io/gh/kaspanet/kaspad/pull/1683/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet#diff-ZG9tYWluL2RhZ2NvbmZpZy9wYXJhbXMuZ28=) | `91.66% <ø> (ø)` | |
| [version/version.go](https://codecov.io/gh/kaspanet/kaspad/pull/1683/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet#diff-dmVyc2lvbi92ZXJzaW9uLmdv) | `37.50% <ø> (ø)` | |
| [app/protocol/flows/blockrelay/handle\_relay\_invs.go](https://codecov.io/gh/kaspanet/kaspad/pull/1683/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet#diff-YXBwL3Byb3RvY29sL2Zsb3dzL2Jsb2NrcmVsYXkvaGFuZGxlX3JlbGF5X2ludnMuZ28=) | `68.75% <0.00%> (-1.25%)` | :arrow_down: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/kaspanet/kaspad/pull/1683?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/kaspanet/kaspad/pull/1683?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet). Last update [dfd8b34...3339c23](https://codecov.io/gh/kaspanet/kaspad/pull/1683?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kaspanet).


Patch:
diff --git a/domain/dagconfig/genesis.go b/domain/dagconfig/genesis.go
index 279d3bcf..be8c12b1 100644
--- a/domain/dagconfig/genesis.go
+++ b/domain/dagconfig/genesis.go
@@ -177,10 +177,10 @@ var testnetGenesisCoinbaseTx = transactionhelper.NewSubnetworkTransaction(0,
 // testnetGenesisHash is the hash of the first block in the block DAG for the test
 // network (genesis block).
 var testnetGenesisHash = externalapi.NewDomainHashFromByteArray(&[externalapi.DomainHashSize]byte{
-	0x8f, 0x83, 0xf5, 0x33, 0x77, 0xa4, 0x80, 0xa7,
-	0x93, 0xf3, 0x17, 0xee, 0x3e, 0x8f, 0xf5, 0xaf,
-	0x16, 0x6d, 0x87, 0x1d, 0x54, 0xfd, 0xe7, 0x79,
-	0xa2, 0xab, 0x6f, 0xc3, 0x76, 0x60, 0xc3, 0x64,
+	0xac, 0x23, 0xff, 0xc3, 0x85, 0xd3, 0x88, 0x99,
+	0xfd, 0xb8, 0x83, 0x30, 0x80, 0x3a, 0x3d, 0xbf,
+	0xf7, 0x9b, 0x96, 0x9e, 0x4c, 0xd5, 0x1b, 0xf0,
+	0x0e, 0x77, 0xb6, 0x87, 0x70, 0xaa, 0x4e, 0x1f,
 })
 
 // testnetGenesisMerkleRoot is the hash of the first transaction in the genesis block
@@ -201,9 +201,9 @@ var testnetGenesisBlock = externalapi.DomainBlock{
 		testnetGenesisMerkleRoot,
 		&externalapi.DomainHash{},
 		externalapi.NewDomainHashFromByteArray(muhash.EmptyMuHashHash.AsArray()),
-		0x177bfd44a10,
+		0x178547bee50,
 		0x1e7fffff,
-		0x64d74,
+		0x2de70,
 	),
 	Transactions: []*externalapi.DomainTransaction{testnetGenesisCoinbaseTx},
 }
diff --git a/domain/dagconfig/params.go b/domain/dagconfig/params.go
index e1675b4f..96d886f7 100644
--- a/domain/dagconfig/params.go
+++ b/domain/dagconfig/params.go
@@ -256,11 +256,11 @@ var MainnetParams = Params{
 // TestnetParams defines the network parameters for the test Kaspa network.
 var TestnetParams = Params{
 	K:           defaultGHOSTDAGK,
-	Name:        "kaspa-testnet-2",
+	Name:        "kaspa-testnet-5",
 	Net:         appmessage.Testnet,
 	RPCPort:     "16210",
 	DefaultPort: "16211",
-	DNSSeeds:    []string{"testnet-2-dnsseed.daglabs-dev.com"},
+	DNSSeeds:    []string{"testnet-5-dnsseed.daglabs-dev.com"},
 
 	// DAG parameters
 	GenesisBlock:                   &testnetGenesisBlock,


Test patch:
diff --git a/domain/consensus/processes/dagtraversalmanager/window_test.go b/domain/consensus/processes/dagtraversalmanager/window_test.go
index 6faa6a5f..cd2f37a4 100644
--- a/domain/consensus/processes/dagtraversalmanager/window_test.go
+++ b/domain/consensus/processes/dagtraversalmanager/window_test.go
@@ -132,37 +132,37 @@ func TestBlockWindow(t *testing.T) {
 			{
 				parents:        []string{"H", "F"},
 				id:             "I",
-				expectedWindow: []string{"F", "D", "H", "C", "G", "B"},
+				expectedWindow: []string{"F", "D", "C", "H", "G", "B"},
 			},
 			{
 				parents:        []string{"I"},
 				id:             "J",
-				expectedWindow: []string{"I", "F", "D", "H", "C", "G", "B"},
+				expectedWindow: []string{"I", "F", "D", "C", "H", "G", "B"},
 			},
 			{
 				parents:        []string{"J"},
 				id:             "K",
-				expectedWindow: []string{"J", "I", "F", "D", "H", "C", "G", "B"},
+				expectedWindow: []string{"J", "I", "F", "D", "C", "H", "G", "B"},
 			},
 			{
 				parents:        []string{"K"},
 				id:             "L",
-				expectedWindow: []string{"K", "J", "I", "F", "D", "H", "C", "G", "B"},
+				expectedWindow: []string{"K", "J", "I", "F", "D", "C", "H", "G", "B"},
 			},
 			{
 				parents:        []string{"L"},
 				id:             "M",
-				expectedWindow: []string{"L", "K", "J", "I", "F", "D", "H", "C", "G", "B"},
+				expectedWindow: []string{"L", "K", "J", "I", "F", "D", "C", "H", "G", "B"},
 			},
 			{
 				parents:        []string{"M"},
 				id:             "N",
-				expectedWindow: []string{"M", "L", "K", "J", "I", "F", "D", "H", "C", "G"},
+				expectedWindow: []string{"M", "L", "K", "J", "I", "F", "D", "C", "H", "G"},
 			},
 			{
 				parents:        []string{"N"},
 				id:             "O",
-				expectedWindow: []string{"N", "M", "L", "K", "J", "I", "F", "D", "H", "C"},
+				expectedWindow: []string{"N", "M", "L", "K", "J", "I", "F", "D", "C", "H"},
 			},
 		},
 		dagconfig.DevnetParams.Name: {