Skip to content

Commit

Permalink
add: testcases
Browse files Browse the repository at this point in the history
  • Loading branch information
rzp-Piyush committed Nov 14, 2024
1 parent 13dc0d5 commit 5890f35
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/i18nify-go/example/example.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,12 @@ func main() {
fmt.Println(state.GetName()) //Karnataka
fmt.Println(state.GetCities()[0]) //{Yellāpur nan Asia/Kolkata [581337 581337 ...}

// Get State details
// Get States by zipcode
madhyaPradesh := countryIN.GetStatesByZipCode("452010")[0]
fmt.Printf("For pincode 452010 state : %s\n", madhyaPradesh) // {[{Wārāseonī nan Asia/Kolkata [481331 ...}
fmt.Printf("State name %s\n", madhyaPradesh.GetName())

// Get Cities by zipcode
cityList := countryIN.GetCitiesByZipCode("452010")
fmt.Println("Cities :")
for _, city := range cityList {
Expand Down

0 comments on commit 5890f35

Please sign in to comment.