Skip to content

Commit

Permalink
fix(rollapp): remove TokenLogoDataUri from rollapp (#1124)
Browse files Browse the repository at this point in the history
  • Loading branch information
zale144 authored Aug 21, 2024
1 parent ff4a34b commit 7883280
Show file tree
Hide file tree
Showing 12 changed files with 93 additions and 160 deletions.
12 changes: 6 additions & 6 deletions app/apptesting/test_suite.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"strings"

bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper"

"github.com/dymensionxyz/dymension/v3/app/params"
dymnstypes "github.com/dymensionxyz/dymension/v3/x/dymns/types"

Expand Down Expand Up @@ -57,12 +58,11 @@ func (s *KeeperTestHelper) CreateRollappByName(name string) {
Alias: strings.ToLower(rand.Str(7)),
VmType: rollapptypes.Rollapp_EVM,
Metadata: &rollapptypes.RollappMetadata{
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
TokenLogoDataUri: "data:image/png;base64,ZHVwZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
},
}

Expand Down
19 changes: 9 additions & 10 deletions app/upgrades/v4/upgrade.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,16 +149,15 @@ func ConvertOldRollappToNew(oldRollapp rollapptypes.Rollapp) rollapptypes.Rollap
GenesisChecksum: string(crypto.Sha256([]byte(oldRollapp.RollappId))), // placeholder data
VmType: rollapptypes.Rollapp_EVM, // placeholder data
Metadata: &rollapptypes.RollappMetadata{
Website: "",
Description: "",
LogoDataUri: "",
TokenLogoDataUri: "",
Telegram: "",
X: "",
GenesisUrl: "",
DisplayName: "",
Tagline: "",
TokenSymbol: "",
Website: "",
Description: "",
LogoDataUri: "",
Telegram: "",
X: "",
GenesisUrl: "",
DisplayName: "",
Tagline: "",
TokenSymbol: "",
},
InitialSequencer: "*",
Sealed: true,
Expand Down
11 changes: 5 additions & 6 deletions ibctesting/utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -132,12 +132,11 @@ func (s *utilSuite) createRollapp(transfersEnabled bool, channelID *string) {
rollapptypes.Rollapp_EVM,

&rollapptypes.RollappMetadata{
Website: "http://example.com",
Description: "Some description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
TokenLogoDataUri: "data:image/png;base64,ZHVwZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
Website: "http://example.com",
Description: "Some description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
},
)

Expand Down
14 changes: 6 additions & 8 deletions proto/dymensionxyz/dymension/rollapp/metadata.proto
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,16 @@ message RollappMetadata {
string description = 2;
// logo_data_uri is a base64 rep with a URI prefix to the rollapp logo. Size limited
string logo_data_uri = 3;
// token_logo_data_uri is a URI to the native token logo. Size limited
string token_logo_data_uri = 4;
// telegram is the rollapp telegram link
string telegram = 5;
string telegram = 4;
// x is the rollapp twitter link
string x = 6;
string x = 5;
// genesis_url has the genesis file
string genesis_url = 7;
string genesis_url = 6;
// display_name is a non semantic name for displaying on gui etc. Size limited.
string display_name = 8;
string display_name = 7;
// tagline is a non semantic tagline/catch-phrase. Size limited.
string tagline = 9;
string tagline = 8;
// token_symbol is the native token symbol
string token_symbol = 10;
string token_symbol = 9;
}
11 changes: 5 additions & 6 deletions x/rollapp/keeper/msg_server_create_rollapp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -384,10 +384,9 @@ func (suite *RollappTestSuite) createRollappWithCreatorAndVerify(
}

var mockRollappMetadata = types.RollappMetadata{
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
TokenLogoDataUri: "data:image/png;base64,ZHVwZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
}
11 changes: 5 additions & 6 deletions x/rollapp/keeper/msg_server_update_rollapp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,12 +137,11 @@ func (suite *RollappTestSuite) TestUpdateRollapp() {
Bech32Prefix: "old",
GenesisChecksum: "old",
Metadata: &types.RollappMetadata{
Website: "",
Description: "",
LogoDataUri: "",
TokenLogoDataUri: "",
Telegram: "",
X: "",
Website: "",
Description: "",
LogoDataUri: "",
Telegram: "",
X: "",
},
}

Expand Down
11 changes: 5 additions & 6 deletions x/rollapp/simulation/create_rollapp.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,11 @@ func SimulateMsgCreateRollapp(ak simulationtypes.AccountKeeper, bk simulationtyp
Bech32Prefix: "rol",
Alias: "rollapp",
Metadata: &types.RollappMetadata{
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
TokenLogoDataUri: "data:image/png;base64,ZHVwZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
},
}

Expand Down
11 changes: 5 additions & 6 deletions x/rollapp/types/message_create_rollapp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,11 @@ func TestMsgCreateRollapp_ValidateBasic(t *testing.T) {
Alias: "Rollapp",
VmType: Rollapp_EVM,
Metadata: &RollappMetadata{
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
TokenLogoDataUri: "data:image/png;base64,ZHVwZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
},
},
},
Expand Down
11 changes: 5 additions & 6 deletions x/rollapp/types/message_update_rollapp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,11 @@ func TestMsgUpdateRollappInformation_ValidateBasic(t *testing.T) {
InitialSequencer: sample.AccAddress(),
GenesisChecksum: "checksum",
Metadata: &RollappMetadata{
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
TokenLogoDataUri: "data:image/png;base64,ZHVwZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
Website: "https://dymension.xyz",
Description: "Sample description",
LogoDataUri: "data:image/png;base64,c2lzZQ==",
Telegram: "https://t.me/rolly",
X: "https://x.dymension.xyz",
},
},
},
Expand Down
Loading

0 comments on commit 7883280

Please sign in to comment.