Skip to content

Commit

Permalink
add more languages unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Sachin-chaurasiya committed Dec 8, 2023
1 parent 050a316 commit b0bc826
Showing 1 changed file with 19 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,25 @@ describe('Test Regex', () => {
// Contains Turkish characters
expect(ENTITY_NAME_REGEX.test('Merhaba dünya')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('Merhaba')).toEqual(true);

// Contains Italian characters
expect(ENTITY_NAME_REGEX.test('Ciao mondo')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('Ciao')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('àèéìíîòóùú')).toEqual(true);

// Contains French characters
expect(ENTITY_NAME_REGEX.test('Bonjour le monde')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('Bonjour')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('àâäéèêëîïôöùûüÿçœæ')).toEqual(true);

// Contains German characters
expect(ENTITY_NAME_REGEX.test('Hallo Welt')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('Hallo')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('äöüÄÖÜß')).toEqual(true);

// Contains Portuguese characters
expect(ENTITY_NAME_REGEX.test('Olá mundo')).toEqual(true);
expect(ENTITY_NAME_REGEX.test('Olá')).toEqual(true);
});

it('EntityName regex should fail for the invalid entity name', () => {
Expand Down

0 comments on commit b0bc826

Please sign in to comment.