Skip to content

Commit

Permalink
Merge pull request #182 from comdex-official/dutch-tests
Browse files Browse the repository at this point in the history
Dutch tests
  • Loading branch information
dheerajkd30 authored Jun 2, 2022
2 parents 8aa903c + 0031eeb commit f0da38e
Show file tree
Hide file tree
Showing 20 changed files with 1,396 additions and 627 deletions.
Empty file modified .scripts/proto-gen.sh
100755 → 100644
Empty file.
Empty file modified .scripts/setup.sh
100755 → 100644
Empty file.
Empty file modified .scripts/shutdown.sh
100755 → 100644
Empty file.
Empty file modified .scripts/startup.sh
100755 → 100644
Empty file.
18 changes: 17 additions & 1 deletion proto/comdex/auction/v1beta1/query.proto
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,22 @@ message QueryDutchBiddingsResponse {
}


message QueryBiddingsForSurplusAuctionRequest {
uint64 app_id = 1;
uint64 auction_mapping_id = 2;
uint64 auction_id = 3;
bool history = 4;
}

message QueryBiddingsForSurplusAuctionResponse {
repeated SurplusBiddings biddings= 1 [
(gogoproto.nullable) = false,
(gogoproto.moretags) = "yaml:\"biddings\""
];
cosmos.base.query.v1beta1.PageResponse pagination = 2
[ (gogoproto.moretags) = "yaml:\"pagination\"" ];
}

message QueryParamsRequest {}

message QueryParamsResponse {
Expand All @@ -173,7 +189,7 @@ service Query {
option (google.api.http).get = "/comdex/auction/v1beta1/surplusbiddings/{bidder}/{app_id}/{history}";
}
rpc QueryDebtAuction(QueryDebtAuctionRequest) returns (QueryDebtAuctionResponse) {
option (google.api.http).get = "/comdex/auction/v1beta1/debtauction/{auction_id}/{app_id}/{auction_mapping_id}/{auction_id}/{history}";
option (google.api.http).get = "/comdex/auction/v1beta1/debtauction/{app_id}/{auction_mapping_id}/{auction_id}/{history}";
}
rpc QueryDebtAuctions(QueryDebtAuctionsRequest) returns (QueryDebtAuctionsResponse) {
option (google.api.http).get = "/comdex/auction/v1beta1/debtauctions/{app_id}/{history}";
Expand Down
3 changes: 3 additions & 0 deletions proto/comdex/collector/v1beta1/collector.proto
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ message AssetToAuctionMapping {
repeated string asset_denoms = 2 [(gogoproto.moretags) = "yaml:\"asset_denoms\""];
}

////////////////////////////////////////////////////////33333333333333

// key app id -> assets traverse this one
message CollectorAuctionLookupTable {
uint64 app_id = 1 [(gogoproto.moretags) = "yaml:\"app_id\""];
repeated AssetIdToAuctionLookupTable assetIdToAuctionLookup = 2 [
Expand Down
4 changes: 2 additions & 2 deletions x/auction/keeper/alias.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ func (k *Keeper) GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string)
return k.bank.GetBalance(ctx, addr, denom)
}

func (k *Keeper) MintCoin(ctx sdk.Context, name string, coin sdk.Coin) error {
func (k *Keeper) MintCoins(ctx sdk.Context, name string, coin sdk.Coin) error {
if coin.IsZero() {
return nil
}

return k.bank.MintCoins(ctx, name, sdk.NewCoins(coin))
}

func (k *Keeper) BurnCoin(ctx sdk.Context, name string, coin sdk.Coin) error {
func (k *Keeper) BurnCoins(ctx sdk.Context, name string, coin sdk.Coin) error {
if coin.IsZero() {
return nil
}
Expand Down
Loading

0 comments on commit f0da38e

Please sign in to comment.