From 5b3530c021479a02213d04035ae527c1edb24758 Mon Sep 17 00:00:00 2001 From: Ahmet Alp Balkan Date: Thu, 21 Jun 2018 22:34:17 -0700 Subject: [PATCH] test-cli: refactor currencyservice smoke test Signed-off-by: Ahmet Alp Balkan --- src/test-cli/main.go | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/test-cli/main.go b/src/test-cli/main.go index 1eeed2e..66efedf 100644 --- a/src/test-cli/main.go +++ b/src/test-cli/main.go @@ -270,17 +270,18 @@ func testCurrencyService() error { log.Printf("--> %v", listResp.GetCurrencyCodes()) log.Println("--- rpc Convert()") + in := &pb.Money{ + CurrencyCode: "CAD", + Amount: &pb.MoneyAmount{ + Decimal: 12, + Fractional: 25}, + } convertResp, err := cl.Convert(context.TODO(), &pb.CurrencyConversionRequest{ - From: &pb.Money{ - CurrencyCode: "CAD", - Amount: &pb.MoneyAmount{ - Decimal: 12, - Fractional: 25}, - }, + From: in, ToCode: "USD"}) if err != nil { return err } - log.Printf("--> result: %+v", convertResp) + log.Printf("--> in=%v result(USD): %+v", in, convertResp) return nil }