File: personal_test.go

package info (click to toggle)
golang-github-jackc-fake 0.0~git20150926.812a484-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 536 kB
  • sloc: makefile: 2
file content (28 lines) | stat: -rw-r--r-- 447 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
package test

import (
	"testing"

	"github.com/icrowley/fake"
)

func TestPersonal(t *testing.T) {
	for _, lang := range fake.GetLangs() {
		fake.SetLang(lang)

		v := fake.Gender()
		if v == "" {
			t.Errorf("Gender failed with lang %s", lang)
		}

		v = fake.GenderAbbrev()
		if v == "" {
			t.Errorf("GenderAbbrev failed with lang %s", lang)
		}

		v = fake.Language()
		if v == "" {
			t.Errorf("Language failed with lang %s", lang)
		}
	}
}