134 references to TestParseSimpleName
Microsoft.CodeAnalysis.UnitTests (134)
MetadataReferences\AssemblyIdentityDisplayNameTests.cs (134)
164TestParseSimpleName("/, Version=1.0.0.0", expected: "/"); 165TestParseSimpleName("\\\\, Version=1.0.0.0", expected: "\\"); 166TestParseSimpleName("\\,\\=, Version=1.0.0.0", expected: ",="); 167TestParseSimpleName("\\\\, Version=1.0.0.0", expected: "\\"); 168TestParseSimpleName("\\/, Version=1.0.0.0", expected: "/"); 169TestParseSimpleName("\\\", Version=1.0.0.0", expected: "\""); 170TestParseSimpleName("\\\', Version=1.0.0.0", expected: "\'"); 171TestParseSimpleName("a\\tb, Version=1.0.0.0", expected: "a\tb"); 172TestParseSimpleName("a\\rb, Version=1.0.0.0", expected: "a\rb"); 173TestParseSimpleName("a\\nb, Version=1.0.0.0", expected: "a\nb"); 174TestParseSimpleName("a\\vb, Version=1.0.0.0", expected: null); 175TestParseSimpleName("a\\fb, Version=1.0.0.0", expected: null); 176TestParseSimpleName("a , Version=1.0.0.0", expected: "a"); 177TestParseSimpleName("a\\a, Version=1.0.0.0", expected: null); 178TestParseSimpleName("a\\ , Version=1.0.0.0", expected: null); 179TestParseSimpleName("a\\ b, Version=1.0.0.0", expected: null); 180TestParseSimpleName("a\\\tb, Version=1.0.0.0", expected: null); 181TestParseSimpleName("a\\\rb, Version=1.0.0.0", expected: null); 182TestParseSimpleName("a\\\nb, Version=1.0.0.0", expected: null); 184TestParseSimpleName("a\\u20;b, Version=1.0.0.0", expected: "a b"); 185TestParseSimpleName("a\\u020;b, Version=1.0.0.0", expected: "a b"); 186TestParseSimpleName("a\\u0020;b, Version=1.0.0.0", expected: "a b"); 187TestParseSimpleName("a\\u1234", expected: null); 188TestParseSimpleName("\\u12345;", expected: "\U00012345"); 189TestParseSimpleName("\\u100000;", expected: "\U00100000"); 190TestParseSimpleName("\\u10fFfF;", expected: "\U0010ffff"); 191TestParseSimpleName("\\u110000;", expected: null); 192TestParseSimpleName("\\u1000000;", expected: null); 193TestParseSimpleName("\\taa, Version=1.0.0.0", expected: "\taa"); 194TestParseSimpleName("a\\", expected: null); 197TestParseSimpleName("\"a\"", expected: "a"); 198TestParseSimpleName("\"a'a\", Version=1.0.0.0", expected: "a'a"); 199TestParseSimpleName("\\\"aa\\\", Version=1.0.0.0", expected: "\"aa\""); 200TestParseSimpleName("\\\"a'a\\\", Version=1.0.0.0", expected: null); 201TestParseSimpleName("\\\"a, Version=1.0.0.0", expected: "\"a"); 202TestParseSimpleName("\", Version=1.0.0.0\", Version=1.0.0.0", expected: ", Version=1.0.0.0"); 203TestParseSimpleName("\", Version=1.0.0.0", expected: ", Version=1.0.0.0"); 204TestParseSimpleName("\\\", Version=1.0.0.0", expected: "\""); 205TestParseSimpleName("xx\\\"abc\\\"xx", expected: "xx\"abc\"xx"); 206TestParseSimpleName("aaa\\\"bbb, Version=1.0.0.0", expected: "aaa\"bbb"); 207TestParseSimpleName("\"b\", Version=1.0.0.0", expected: "b"); 208TestParseSimpleName(" \"b\" , Version=1.0.0.0", expected: "b"); 209TestParseSimpleName("\"abc', Version=1.0.0.0", expected: "abc', Version=1.0.0.0"); 210TestParseSimpleName("'\"a\"', Version=1.0.0.0", expected: "\"a\""); 211TestParseSimpleName("'xxx\"xxx\"xxx', Version=1.0.0.0", expected: "xxx\"xxx\"xxx"); 212TestParseSimpleName("'xxx\\\"xxx\\'xxx', Version=1.0.0.0", expected: "xxx\"xxx'xxx"); 213TestParseSimpleName("b\", Version=1.0.0.0", expected: null); 214TestParseSimpleName("aaa\"b\"bb, Version=1.0.0.0", expected: null); 215TestParseSimpleName("a\"b, Version=1.0.0.0", expected: null); 216TestParseSimpleName("\"\", Version=1.0.0.0", expected: null); 217TestParseSimpleName("\"\"a\"\", Version=1.0.0.0", expected: null); 220TestParseSimpleName("'a'", expected: "a"); 221TestParseSimpleName("'a\"a', Version=1.0.0.0", expected: "a\"a"); 222TestParseSimpleName("\\'aa\\', Version=1.0.0.0", expected: "'aa'"); 223TestParseSimpleName("\\'a\"a\\', Version=1.0.0.0", expected: null); 224TestParseSimpleName("\\'a,Version=1.0.0.0", expected: "'a"); 225TestParseSimpleName("', Version=1.0.0.0', Version=1.0.0.0", expected: ", Version=1.0.0.0"); 226TestParseSimpleName("', Version=1.0.0.0", expected: ", Version=1.0.0.0"); 227TestParseSimpleName("\\', Version=1.0.0.0", expected: "'"); 228TestParseSimpleName("xx\\'abc\\'xx", expected: "xx'abc'xx"); 229TestParseSimpleName("aaa\\'bbb, Version=1.0.0.0", expected: "aaa'bbb"); 230TestParseSimpleName("'b', Version=1.0.0.0", expected: "b"); 231TestParseSimpleName(" 'b' , Version=1.0.0.0", expected: "b"); 232TestParseSimpleName("'abc\", Version=1.0.0.0", expected: "abc\", Version=1.0.0.0"); 233TestParseSimpleName("\"'a'\", Version=1.0.0.0", expected: "'a'"); 234TestParseSimpleName("\"xxx'xxx'xxx\", Version=1.0.0.0", expected: "xxx'xxx'xxx"); 235TestParseSimpleName("\"xxx\\\"xxx\\'xxx\", Version=1.0.0.0", expected: "xxx\"xxx'xxx"); 236TestParseSimpleName("b', Version=1.0.0.0", expected: null); 237TestParseSimpleName("aaa'b'bb, Version=1.0.0.0", expected: null); 238TestParseSimpleName("a'b, Version=1.0.0.0", expected: null); 239TestParseSimpleName("'', Version=1.0.0.0", expected: null); 240TestParseSimpleName("''a'', Version=1.0.0.0", expected: null); 243TestParseSimpleName("\u201ca\u201d", expected: "\u201ca\u201d"); 244TestParseSimpleName("\\u201c;a\\u201d;", expected: "\u201ca\u201d"); 245TestParseSimpleName("\u201ca", expected: "\u201ca"); 246TestParseSimpleName("\\u201c;a", expected: "\u201ca"); 247TestParseSimpleName("a\u201d", expected: "a\u201d"); 248TestParseSimpleName("a\\u201d;", expected: "a\u201d"); 249TestParseSimpleName("\u201ca\u201d ", expected: "\u201ca\u201d"); 250TestParseSimpleName("\\u201c;a\\u201d; ", expected: "\u201ca\u201d"); 251TestParseSimpleName("\u2018a\u2019", expected: "\u2018a\u2019"); 252TestParseSimpleName("\\u2018;a\\u2019;", expected: "\u2018a\u2019"); 253TestParseSimpleName("\u2018a", expected: "\u2018a"); 254TestParseSimpleName("\\u2018;a", expected: "\u2018a"); 255TestParseSimpleName("a\u2019", expected: "a\u2019"); 256TestParseSimpleName("a\\u2019;", expected: "a\u2019"); 257TestParseSimpleName("\u2018a\u2019 ", expected: "\u2018a\u2019"); 258TestParseSimpleName("\\u2018;a\\u2019; ", expected: "\u2018a\u2019"); 261TestParseSimpleName(" \0 , Version=1.0.0.0", expected: null); 262TestParseSimpleName("zzz, Version=1.0.0\0.0", null); 263TestParseSimpleName("\0", expected: null); 266TestParseSimpleName("\t, Version=1.0.0.0", expected: null); 267TestParseSimpleName("\r, Version=1.0.0.0", expected: null); 268TestParseSimpleName("\n, Version=1.0.0.0", expected: null); 269TestParseSimpleName(" , Version=1.0.0.0", expected: null); 272TestParseSimpleName("\" a \"", expected: " a "); 273TestParseSimpleName("' a '", expected: " a "); 274TestParseSimpleName("'\r\t\n', Version=1.0.0.0", expected: "\r\t\n"); 275TestParseSimpleName("\"\r\t\n\", Version=1.0.0.0", expected: "\r\t\n"); 276TestParseSimpleName("x\n\t\nx, Version=1.0.0.0", expected: "x\n\t\nx"); 279TestParseSimpleName("=", null); 280TestParseSimpleName(",", null); 281TestParseSimpleName("a,", null); 282TestParseSimpleName("a ,", null); 283TestParseSimpleName("\"a\"=", expected: null); 284TestParseSimpleName("\"a\" =", expected: null); 285TestParseSimpleName("\"a\",", expected: null); 286TestParseSimpleName("\"a\" ,", expected: null); 287TestParseSimpleName("'a'=", expected: null); 288TestParseSimpleName("'a' =", expected: null); 289TestParseSimpleName("'a',", expected: null); 290TestParseSimpleName("'a' ,", expected: null); 293TestParseSimpleName(" \"a\" ", expected: "a"); 294TestParseSimpleName(" 'a' ", expected: "a"); 295TestParseSimpleName(" x, Version=1.0.0.0", expected: "x"); 296TestParseSimpleName(" x\t\r\n , Version=1.0.0.0", expected: "x"); 297TestParseSimpleName("\u0008x, Version=1.0.0.0", expected: "\u0008x"); 298TestParseSimpleName("\u0085x, Version=1.0.0.0", expected: "\u0085x"); 299TestParseSimpleName("\u00A0x, Version=1.0.0.0", expected: "\u00A0x"); 300TestParseSimpleName("\u2000x, Version=1.0.0.0", expected: "\u2000x"); 301TestParseSimpleName("x x, Version=1.0.0.0", expected: "x x"); 302TestParseSimpleName(" \"a'a\" , Version=1.0.0.0", expected: "a'a"); 303TestParseSimpleName(" \"aa\" x , Version=1.0.0.0", expected: null); 304TestParseSimpleName(" \"aa\" \"\" , Version=1.0.0.0", expected: null); 305TestParseSimpleName(" \"aa\" \'\' , Version=1.0.0.0", expected: null); 306TestParseSimpleName(" A", "A"); 307TestParseSimpleName("A ", "A"); 308TestParseSimpleName(" A ", "A"); 309TestParseSimpleName(" A, Version=1.0.0.0", "A"); 310TestParseSimpleName("A , Version=1.0.0.0", "A"); 311TestParseSimpleName("A , Version=1.0.0.0", "A"); 316TestParseSimpleName("goo" + c, "goo" + c); 321TestParseSimpleName("hello 'xxx', Version=1.0.0.0", expected: null); 330TestParseSimpleName(dn, simpleName);