aliasmgr: export StartingAlias so other packages can use it
This commit is contained in:
2 files changed
+10
-10
No files matched your search
@@ -32,12 +32,12 @@ func TestAliasStorePeerAlias(t *testing.T) {
|
||||
|
||||
// Test that we can put the (chanID, alias) mapping in the database.
|
||||
// Also check that we retrieve exactly what we put in.
|
||||
err = aliasStore.PutPeerAlias(chanID1, startingAlias)
|
||||
err = aliasStore.PutPeerAlias(chanID1, StartingAlias)
|
||||
require.NoError(t, err)
|
||||
|
||||
storedAlias, err := aliasStore.GetPeerAlias(chanID1)
|
||||
require.NoError(t, err)
|
||||
require.Equal(t, startingAlias, storedAlias)
|
||||
require.Equal(t, StartingAlias, storedAlias)
|
||||
}
|
||||
|
||||
// TestAliasStoreRequest tests that the aliasStore delivers the expected SCID.
|
||||
@@ -55,12 +55,12 @@ func TestAliasStoreRequest(t *testing.T) {
|
||||
aliasStore, err := NewManager(db)
|
||||
require.NoError(t, err)
|
||||
|
||||
// We'll assert that the very first alias we receive is startingAlias.
|
||||
// We'll assert that the very first alias we receive is StartingAlias.
|
||||
alias1, err := aliasStore.RequestAlias()
|
||||
require.NoError(t, err)
|
||||
require.Equal(t, startingAlias, alias1)
|
||||
require.Equal(t, StartingAlias, alias1)
|
||||
|
||||
// The next alias should be the result of passing in startingAlias to
|
||||
// The next alias should be the result of passing in StartingAlias to
|
||||
// getNextScid.
|
||||
nextAlias := getNextScid(alias1)
|
||||
alias2, err := aliasStore.RequestAlias()
|
||||
@@ -78,7 +78,7 @@ func TestGetNextScid(t *testing.T) {
|
||||
}{
|
||||
{
|
||||
name: "starting alias",
|
||||
current: startingAlias,
|
||||
current: StartingAlias,
|
||||
expected: lnwire.ShortChannelID{
|
||||
BlockHeight: uint32(startingBlockHeight),
|
||||
TxIndex: 0,
|
||||
|
||||
Reference in new issue
Block a user