@@ -2,19 +2,19 @@ import { areEmailAddressesValid, isEmailAddressValid } from '@hypertrace/common'
2
2
3
3
describe ( 'Email validator' , ( ) => {
4
4
test ( 'can validate email correctly' , ( ) => {
5
- expect ( isEmailAddressValid ( 'test@traceable .ai' ) ) . toBe ( true ) ;
6
- expect ( isEmailAddressValid ( 'test.email@traceable .ai' ) ) . toBe ( true ) ;
7
- expect ( isEmailAddressValid ( 'test+983tonq@traceable .ai' ) ) . toBe ( true ) ;
8
- expect ( isEmailAddressValid ( 'test@traceable .' ) ) . toBe ( false ) ;
5
+ expect ( isEmailAddressValid ( 'test@test .ai' ) ) . toBe ( true ) ;
6
+ expect ( isEmailAddressValid ( 'test.email@test .ai' ) ) . toBe ( true ) ;
7
+ expect ( isEmailAddressValid ( 'test+983tonq@test .ai' ) ) . toBe ( true ) ;
8
+ expect ( isEmailAddressValid ( 'test@test .' ) ) . toBe ( false ) ;
9
9
expect ( isEmailAddressValid ( 'test' ) ) . toBe ( false ) ;
10
- expect ( isEmailAddressValid ( 'test@traceable -' ) ) . toBe ( false ) ;
11
- expect ( isEmailAddressValid ( 'tes\t@traceable -' ) ) . toBe ( false ) ;
12
- expect ( isEmailAddressValid ( 'test@@traceable .ai' ) ) . toBe ( false ) ;
13
- expect ( isEmailAddressValid ( 'test@@traceable .ai' ) ) . toBe ( false ) ;
10
+ expect ( isEmailAddressValid ( 'test@test -' ) ) . toBe ( false ) ;
11
+ expect ( isEmailAddressValid ( 'tes\t@test -' ) ) . toBe ( false ) ;
12
+ expect ( isEmailAddressValid ( 'test@@test .ai' ) ) . toBe ( false ) ;
13
+ expect ( isEmailAddressValid ( 'test@@test .ai' ) ) . toBe ( false ) ;
14
14
} ) ;
15
15
16
16
test ( 'can validate email lists correctly' , ( ) => {
17
- expect ( areEmailAddressesValid ( [ 'test@traceable .ai' , 'test.email@traceable .ai' ] ) ) . toBe ( true ) ;
18
- expect ( areEmailAddressesValid ( [ 'test@traceable .ai' , 'test.email@@traceable .ai' ] ) ) . toBe ( false ) ;
17
+ expect ( areEmailAddressesValid ( [ 'test@test .ai' , 'test.email@test .ai' ] ) ) . toBe ( true ) ;
18
+ expect ( areEmailAddressesValid ( [ 'test@test .ai' , 'test.email@@test .ai' ] ) ) . toBe ( false ) ;
19
19
} ) ;
20
20
} ) ;
0 commit comments