Created
November 28, 2017 13:21
-
-
Save c1982/6b17e1df5f46dccca3ed1e94dede8d8d to your computer and use it in GitHub Desktop.
Old golang test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package yaziya | |
import ( | |
"testing" | |
) | |
func Test_Yaziya_Cevir_Birler(t *testing.T) { | |
var price float64 | |
price = 5 | |
text, err := Cevir(price) | |
if err != nil { | |
t.Error(err) | |
} | |
if text != "beş" { | |
t.Error("Text:", text) | |
} | |
} | |
func Test_Yaziya_Cevir_Onlar(t *testing.T) { | |
var price float64 | |
price = 25 | |
text, err := Cevir(price) | |
if err != nil { | |
t.Error(err) | |
} | |
if text != "yirmibeş" { | |
t.Error("Text:", text) | |
} | |
} | |
func Test_Yaziya_Cevir_Yuzler(t *testing.T) { | |
var price float64 | |
price = 587 | |
text, err := Cevir(price) | |
if err != nil { | |
t.Error(err) | |
} | |
if text != "beşyüzseksenyedi" { | |
t.Error("Text:", text) | |
} | |
} | |
func Test_Yaziya_Cevir_Binler(t *testing.T) { | |
var price float64 | |
price = 1458 | |
text, err := Cevir(price) | |
if err != nil { | |
t.Error(err) | |
} | |
if text != "bin dörtyüzellisekiz" { | |
t.Error("Text:", text) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment