aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMatt Mayer <[email protected]>2024-02-28 02:41:48 +0700
committerGitHub <[email protected]>2024-02-27 20:41:48 +0100
commit0d4cba637cdd38e7757ecca1b7eae75d7a737fa8 (patch)
tree27983120b5d0d1d940b6dc273e0faebee76ff74d /test
parent682a4276f13d7b8f48e1bd8aafcf011c7bd10390 (diff)
downloadfaker-0d4cba637cdd38e7757ecca1b7eae75d7a737fa8.tar.xz
faker-0d4cba637cdd38e7757ecca1b7eae75d7a737fa8.zip
refactor(person)!: flatten jobs definitions (#2505)
Diffstat (limited to 'test')
-rw-r--r--test/all-functional.spec.ts4
-rw-r--r--test/modules/person.spec.ts16
2 files changed, 6 insertions, 14 deletions
diff --git a/test/all-functional.spec.ts b/test/all-functional.spec.ts
index b1819428..5f7618ff 100644
--- a/test/all-functional.spec.ts
+++ b/test/all-functional.spec.ts
@@ -61,10 +61,6 @@ const BROKEN_LOCALE_METHODS = {
person: {
prefix: ['az', 'id_ID', 'ru', 'zh_CN', 'zh_TW'],
suffix: ['az', 'it', 'mk', 'pt_PT', 'ro_MD', 'ru'],
- jobArea: ['ar'],
- jobDescriptor: ['ar'],
- jobTitle: ['ar', 'ur'],
- jobType: ['ur'],
},
} satisfies {
[module_ in keyof Faker]?: SkipConfig<Faker[module_]>;
diff --git a/test/modules/person.spec.ts b/test/modules/person.spec.ts
index 1af3dfb8..1b831217 100644
--- a/test/modules/person.spec.ts
+++ b/test/modules/person.spec.ts
@@ -262,11 +262,9 @@ describe('person', () => {
const [descriptor, level, job] = jobTitle.split(' ');
- expect(faker.definitions.person.title.descriptor).toContain(
- descriptor
- );
- expect(faker.definitions.person.title.level).toContain(level);
- expect(faker.definitions.person.title.job).toContain(job);
+ expect(faker.definitions.person.job_descriptor).toContain(descriptor);
+ expect(faker.definitions.person.job_area).toContain(level);
+ expect(faker.definitions.person.job_type).toContain(job);
});
});
@@ -276,9 +274,7 @@ describe('person', () => {
expect(descriptor).toBeTypeOf('string');
- expect(faker.definitions.person.title.descriptor).toContain(
- descriptor
- );
+ expect(faker.definitions.person.job_descriptor).toContain(descriptor);
});
});
@@ -288,7 +284,7 @@ describe('person', () => {
expect(level).toBeTypeOf('string');
- expect(faker.definitions.person.title.level).toContain(level);
+ expect(faker.definitions.person.job_area).toContain(level);
});
});
@@ -298,7 +294,7 @@ describe('person', () => {
expect(job).toBeTypeOf('string');
- expect(faker.definitions.person.title.job).toContain(job);
+ expect(faker.definitions.person.job_type).toContain(job);
});
});