cuelang.org/go@v0.13.0/encoding/jsonschema/testdata/external/tests/draft2020-12/optional/format/email.json (about)

     1  [
     2  	{
     3  		"description": "validation of e-mail addresses",
     4  		"schema": {
     5  			"$schema": "https://json-schema.org/draft/2020-12/schema",
     6  			"format": "email"
     7  		},
     8  		"tests": [
     9  			{
    10  				"description": "all string formats ignore integers",
    11  				"data": 12,
    12  				"valid": true
    13  			},
    14  			{
    15  				"description": "all string formats ignore floats",
    16  				"data": 13.7,
    17  				"valid": true
    18  			},
    19  			{
    20  				"description": "all string formats ignore objects",
    21  				"data": {},
    22  				"valid": true
    23  			},
    24  			{
    25  				"description": "all string formats ignore arrays",
    26  				"data": [],
    27  				"valid": true
    28  			},
    29  			{
    30  				"description": "all string formats ignore booleans",
    31  				"data": false,
    32  				"valid": true
    33  			},
    34  			{
    35  				"description": "all string formats ignore nulls",
    36  				"data": null,
    37  				"valid": true
    38  			},
    39  			{
    40  				"description": "a valid e-mail address",
    41  				"data": "joe.bloggs@example.com",
    42  				"valid": true
    43  			},
    44  			{
    45  				"description": "an invalid e-mail address",
    46  				"data": "2962",
    47  				"valid": false,
    48  				"skip": {
    49  					"v2": "unexpected success",
    50  					"v3": "unexpected success"
    51  				}
    52  			},
    53  			{
    54  				"description": "tilde in local part is valid",
    55  				"data": "te~st@example.com",
    56  				"valid": true
    57  			},
    58  			{
    59  				"description": "tilde before local part is valid",
    60  				"data": "~test@example.com",
    61  				"valid": true
    62  			},
    63  			{
    64  				"description": "tilde after local part is valid",
    65  				"data": "test~@example.com",
    66  				"valid": true
    67  			},
    68  			{
    69  				"description": "a quoted string with a space in the local part is valid",
    70  				"data": "\"joe bloggs\"@example.com",
    71  				"valid": true
    72  			},
    73  			{
    74  				"description": "a quoted string with a double dot in the local part is valid",
    75  				"data": "\"joe..bloggs\"@example.com",
    76  				"valid": true
    77  			},
    78  			{
    79  				"description": "a quoted string with a @ in the local part is valid",
    80  				"data": "\"joe@bloggs\"@example.com",
    81  				"valid": true
    82  			},
    83  			{
    84  				"description": "an IPv4-address-literal after the @ is valid",
    85  				"data": "joe.bloggs@[127.0.0.1]",
    86  				"valid": true
    87  			},
    88  			{
    89  				"description": "an IPv6-address-literal after the @ is valid",
    90  				"data": "joe.bloggs@[IPv6:::1]",
    91  				"valid": true
    92  			},
    93  			{
    94  				"description": "dot before local part is not valid",
    95  				"data": ".test@example.com",
    96  				"valid": false,
    97  				"skip": {
    98  					"v2": "unexpected success",
    99  					"v3": "unexpected success"
   100  				}
   101  			},
   102  			{
   103  				"description": "dot after local part is not valid",
   104  				"data": "test.@example.com",
   105  				"valid": false,
   106  				"skip": {
   107  					"v2": "unexpected success",
   108  					"v3": "unexpected success"
   109  				}
   110  			},
   111  			{
   112  				"description": "two separated dots inside local part are valid",
   113  				"data": "te.s.t@example.com",
   114  				"valid": true
   115  			},
   116  			{
   117  				"description": "two subsequent dots inside local part are not valid",
   118  				"data": "te..st@example.com",
   119  				"valid": false,
   120  				"skip": {
   121  					"v2": "unexpected success",
   122  					"v3": "unexpected success"
   123  				}
   124  			},
   125  			{
   126  				"description": "an invalid domain",
   127  				"data": "joe.bloggs@invalid=domain.com",
   128  				"valid": false,
   129  				"skip": {
   130  					"v2": "unexpected success",
   131  					"v3": "unexpected success"
   132  				}
   133  			},
   134  			{
   135  				"description": "an invalid IPv4-address-literal",
   136  				"data": "joe.bloggs@[127.0.0.300]",
   137  				"valid": false,
   138  				"skip": {
   139  					"v2": "unexpected success",
   140  					"v3": "unexpected success"
   141  				}
   142  			}
   143  		]
   144  	}
   145  ]