438 references to WriteAllText
InteractiveHost.UnitTests (15)
InteractiveHostCoreInitTests.cs (1)
58
srcDir.CreateFile("goo.csx").
WriteAllText
("ReferencePaths.Add(@\"" + dllDir + "\");");
InteractiveHostDesktopInitTests.cs (1)
31
srcDir.CreateFile("goo.csx").
WriteAllText
("ReferencePaths.Add(@\"" + dllDir + "\");");
InteractiveHostDesktopTests.cs (13)
182
var file = Temp.CreateFile().
WriteAllText
(MethodWithInfiniteLoop + "\r\nfoo();").Path;
201
var file = Temp.CreateFile().
WriteAllText
("1 1").Path;
224
var file = Temp.CreateFile().
WriteAllText
(@"
270
var file = Temp.CreateFile().
WriteAllText
("#load blah.csx" + "\r\n" + "class C {}");
693
initFile.
WriteAllText
(@"
704
rspFile.
WriteAllText
($"/lib:{directory1.Path} /r:Assembly2.dll {initFile.Path}");
736
initFile.
WriteAllText
(@"#r ""Assembly.dll""");
742
rspFile.
WriteAllText
($"{initFile.Path}");
755
rspFile.
WriteAllText
(@"
810
var initFile = Temp.CreateFile(extension: ".csx").
WriteAllText
("1 1");
814
rspFile.
WriteAllText
($@"
838
var scriptFile = Temp.CreateFile(extension: ".csx").
WriteAllText
("foreach (var arg in Args) Print(arg);");
841
rspFile.
WriteAllText
($@"
Microsoft.Build.Tasks.CodeAnalysis.UnitTests (36)
DotNetSdkTests.cs (25)
26
var libFile = sourcePackageDir.CreateFile("lib.cs").
WriteAllText
("class Lib { public void M() { } }");
316
ProjectDir.CreateFile("Project2.csproj").
WriteAllText
($@"
410
var srcFile = ProjectDir.CreateFile("lib1.cs").
WriteAllText
("class C { }");
412
var srcFile2 = subdir.CreateFile("lib2.cs").
WriteAllText
("class D { }");
413
var editorConfigFile2 = subdir.CreateFile(".editorconfig").
WriteAllText
(@"[*.cs]
440
var srcFile = ProjectDir.CreateFile("lib1.cs").
WriteAllText
("class C { }");
442
var srcFile2 = subdir.CreateFile("lib2.cs").
WriteAllText
("class D { }");
443
var editorConfigFile2 = subdir.CreateFile(".editorconfig").
WriteAllText
(@"[*.cs]
468
var srcFile = ProjectDir.CreateFile("lib1.cs").
WriteAllText
("class C { }");
469
var globalConfigFile = ProjectDir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
472
var srcFile2 = subdir.CreateFile("lib2.cs").
WriteAllText
("class D { }");
473
var globalConfigFile2 = subdir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
502
var srcFile = ProjectDir.CreateFile("lib1.cs").
WriteAllText
("class C { }");
503
var globalConfigFile = ProjectDir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
506
var srcFile2 = subdir.CreateFile("lib2.cs").
WriteAllText
("class D { }");
507
var globalConfigFile2 = subdir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
535
var srcFile = ProjectDir.CreateFile("lib1.cs").
WriteAllText
("class C { }");
536
var globalConfigFile = ProjectDir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
539
var srcFile2 = subdir.CreateFile("lib2.cs").
WriteAllText
("class D { }");
540
var globalConfigFile2 = subdir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
599
var srcFile = ProjectDir.CreateFile("lib1.cs").
WriteAllText
("class C { }");
600
var globalConfigFile = ProjectDir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
603
var globalConfigFile2 = subdir.CreateFile(".globalconfig").
WriteAllText
(@"is_global = true
629
var srcFile = ProjectDir.CreateFile("lib1.cs").
WriteAllText
("class C { }");
630
var globalConfigFile = ProjectDir.CreateFile("mycustom.config").
WriteAllText
(@"is_global = true
IntegrationTests.cs (6)
81
file.
WriteAllText
(pair.Value);
619
var slnFile = testDir.CreateFile("Console;!@(goo)'^(Application1.sln").
WriteAllText
(
648
var appProjFile = appDir.CreateFile(@"Cons.ole;!@(goo)'^(Application1.csproj").
WriteAllText
(
698
var appProgramFile = appDir.CreateFile("Program.cs").
WriteAllText
(
716
var libraryProjFile = libraryDir.CreateFile("Class;!@(goo)'^(Library1.csproj").
WriteAllText
(
772
var libraryClassFile = libraryDir.CreateFile("Class1.cs").
WriteAllText
(
TestUtilities\DotNetSdkTestBase.cs (5)
166
Project = ProjectDir.CreateFile(ProjectFileName).
WriteAllText
(s_projectSource);
167
ProjectDir.CreateFile("TestClass.cs").
WriteAllText
(s_classSource);
170
ProjectDir.CreateFile("Directory.Build.props").
WriteAllText
("<Project/>");
171
ProjectDir.CreateFile("Directory.Build.targets").
WriteAllText
("<Project/>");
172
ProjectDir.CreateFile(".editorconfig").
WriteAllText
("root = true");
Microsoft.CodeAnalysis.CSharp.CommandLine.UnitTests (55)
CommandLineIVTTests.cs (4)
26
var source2 = dir.CreateFile("B.cs").
WriteAllText
("""
103
var source2 = dir.CreateFile("B.cs").
WriteAllText
("""
181
var source2 = dir.CreateFile("B.cs").
WriteAllText
("""
264
var source2 = dir.CreateFile("B.cs").
WriteAllText
("""
CommandLineTests.cs (31)
138
var src = dir.CreateFile("temp.cs").
WriteAllText
(@"
163
var src = dir.CreateFile("temp.cs").
WriteAllText
("class C {}");
187
var src = dir.CreateFile("test.cs").
WriteAllText
(@"
192
var analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
(@"
217
var src = dir.CreateFile("Class1.cs").
WriteAllText
("""
229
var editorconfig = dir.CreateFile(".editorconfig").
WriteAllText
("""
273
var src = dir.CreateFile("test.cs").
WriteAllText
(@"
279
var analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
(@"
332
var src = dir.CreateFile("test.cs").
WriteAllText
(@"
337
var analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
(@"
364
var src = dir.CreateFile("test.cs").
WriteAllText
(@"
373
var analyzerConfig1 = dir.CreateFile("analyzerconfig1").
WriteAllText
(configText);
374
var analyzerConfig2 = dir.CreateFile("analyzerconfig2").
WriteAllText
(configText);
447
string rsp = Temp.CreateFile().
WriteAllText
(@"
580
file.
WriteAllText
(source);
742
f.
WriteAllText
("");
1230
file1.
WriteAllText
("");
1231
file2.
WriteAllText
("");
1232
file3.
WriteAllText
("");
1233
file4.
WriteAllText
("");
1234
file5.
WriteAllText
("");
2244
src.
WriteAllText
(@"class C { public static void Main() {} }");
2247
sl.
WriteAllText
(@"{ ""documents"" : {} }");
2276
src.
WriteAllText
(@"class C { public static void Main() {} }");
2279
sl.
WriteAllText
(@"{ ""documents"" : {} }");
2304
src.
WriteAllText
(@"class C { public static void Main() {} }");
2433
src.
WriteAllText
(embed_cs);
2434
src2.
WriteAllText
(embed2_cs);
2435
txt.
WriteAllText
(embed_xyz);
9287
TempFile tempFile = tempDir.CreateFile("a.cs").
WriteAllText
(@"public class A { }");
11620
var src = dir.CreateFile("a.cs").
WriteAllText
(source);
SarifErrorLoggerTests.cs (9)
41
var hello = Temp.CreateFile().
WriteAllText
(helloWorldCS).Path;
72
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
106
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
138
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
175
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
210
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
245
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
280
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
313
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
SarifV2ErrorLoggerTests.cs (6)
445
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
525
var sourceFile1 = sourceDir.CreateFile("source1.cs").
WriteAllText
(source1).Path;
526
var sourceFile2 = sourceDir.CreateFile("source2.cs").
WriteAllText
(source2).Path;
527
var editorconfigFile = sourceDir.CreateFile(".editorconfig").
WriteAllText
(editorconfigText).Path;
597
var sourceFile = Temp.CreateFile().
WriteAllText
(source).Path;
678
var sourceFile = errorLogDir.CreateFile("myfile.cs").
WriteAllText
(source);
TouchedFileLoggingTests.cs (5)
38
var hello = Temp.CreateFile().
WriteAllText
(helloWorldCS).Path;
66
var hello = Temp.CreateFile().
WriteAllText
(helloWorldCS).Path;
69
var appConfigPath = Temp.CreateFile().
WriteAllText
(
112
var hello = Temp.CreateFile().
WriteAllText
(helloWorldCS).Path;
147
var sourcePath = Temp.CreateFile().
WriteAllText
(@"
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (2)
Attributes\AttributeTests_Security.cs (2)
1486
tempFile.
WriteAllText
(text);
1575
tempFile.
WriteAllText
(text);
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (19)
CommandLineRunnerTests.cs (19)
264
var script = Temp.CreateFile(extension: ".csx").
WriteAllText
("foreach (var arg in Args) Print(arg);");
266
var rsp = Temp.CreateFile(extension: ".rsp").
WriteAllText
($@"
297
var script = Temp.CreateFile(extension: ".csx").
WriteAllText
("foreach (var arg in Args) Print(arg);");
314
var script = Temp.CreateFile(extension: ".csx").
WriteAllText
("foreach (var arg in Args) Print(arg);");
331
var script = Temp.CreateFile(extension: ".csx").
WriteAllText
("foreach (var arg in Args) Print(arg);");
333
var rsp = Temp.CreateFile(extension: ".rsp").
WriteAllText
($@"
363
var script = Temp.CreateFile(prefix: "@", extension: ".csx").
WriteAllText
("foreach (var arg in Args) Print(arg);");
381
var script = dir.CreateFile("--").
WriteAllText
("foreach (var arg in Args) Print(arg);");
446
var script = Temp.CreateFile(extension: ".csx").
WriteAllText
("WriteLine(42);");
487
var script = directory.CreateFile(scriptName).
WriteAllText
("Print(3);");
527
var main = Temp.CreateFile(extension: ".csx").
WriteAllText
(@"
535
dir1.CreateFile("1.csx").
WriteAllText
(@"Print(1);");
538
dir2.CreateFile("2.csx").
WriteAllText
(@"Print(2);");
541
dir3.CreateFile("3.csx").
WriteAllText
(@"Print(3);");
558
var main = Temp.CreateFile(extension: ".csx").
WriteAllText
(@"
596
var main = dir.CreateFile("a.csx").
WriteAllText
("int X = 1;");
667
var rsp = Temp.CreateFile().
WriteAllText
(@"
706
var init = Temp.CreateFile(extension: ".csx").
WriteAllText
(@"
726
var init = Temp.CreateFile(extension: ".csx").
WriteAllText
(@"
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (1)
Semantics\SemanticErrorTests.cs (1)
21969
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("&");
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (50)
DocumentationComments\DocumentationCommentCompilerTests.cs (49)
3441
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
3476
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
3514
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
3549
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
3585
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
3646
var dir1XmlFile = dir1.CreateFile("test.xml").
WriteAllText
(xml1);
3649
var dir2XmlFile = dir2.CreateFile("test.xml").
WriteAllText
(xml2);
3652
var dir3XmlFile = dir3.CreateFile("test.xml").
WriteAllText
(xml3);
3733
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
3804
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
3876
var xmlFile2 = Temp.CreateFile(extension: ".xml").
WriteAllText
(string.Format("<include file='{0}' path='path'/>", xmlFilePath1));
3909
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("<element/>");
3943
var xmlFile1 = Temp.CreateFile(extension: ".xml").
WriteAllText
("<element/>");
3946
var xmlFile2 = Temp.CreateFile(extension: ".xml").
WriteAllText
(string.Format("<include file='{0}' path=':'/>", xmlFilePath1));
3976
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("<OpenWithoutClose>");
4010
var xmlFile1 = Temp.CreateFile(extension: ".xml").
WriteAllText
("<OpenWithoutClose>");
4013
var xmlFile2 = Temp.CreateFile(extension: ".xml").
WriteAllText
(string.Format("<include file='{0}' path='path'/>", xmlFilePath1));
4046
xmlFile.
WriteAllText
(string.Format(@"<include file=""{0}"" path=""//include""/>", xmlFilePath)); //Includes itself.
4078
xmlFile.
WriteAllText
(string.Format(@"<parent><include file=""{0}"" path=""//parent""/></parent>", xmlFilePath)); //Includes its parent.
4112
xmlFile.
WriteAllText
(string.Format(@"
4171
xmlFile.
WriteAllText
(string.Format(xmlTemplate, xmlFilePath));
4211
xmlFile1.
WriteAllText
(string.Format(xmlTemplate1, xmlFilePath2));
4212
xmlFile2.
WriteAllText
(xml2);
4244
xmlFile.
WriteAllText
(@"<?xml version=""1.0""?>
4318
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<see cref=""Main""/>");
4353
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<see cref=""M:Verbatim""/>");
4388
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<see cref=""Int32""/>");
4435
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<see cref=""#""/>");
4476
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<see cref=""Invalid""/>");
4530
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(seeElement);
4575
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(seeElement);
4652
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
4732
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
4803
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
4847
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<typeparam name=""#""/>");
4885
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<param name=""Q""/>");
4926
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<param name=""x""/>");
4962
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(@"<param name=""x"" name=""y""/>");
5004
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
5074
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
5243
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("<stuff />");
5957
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("&");
7212
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
7301
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("<hello/>");
7324
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("<hello/>");
7343
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
("<hello/>");
7381
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(
7446
xmlFile.
WriteAllText
(string.Format(xmlTemplate, xmlFilePath));
7601
var xmlFile = dir.CreateFile("---.xml").
WriteAllText
(@"<summary attrib="""" attrib=""""/>");
DocumentationComments\DocumentationModeTests.cs (1)
368
var xmlFile = Temp.CreateFile(extension: ".xml").
WriteAllText
(xml);
Microsoft.CodeAnalysis.Scripting.Desktop.UnitTests (6)
MetadataShadowCopyProviderTests.cs (6)
86
var doc = dir.CreateFile("a.xml").
WriteAllText
("<hello>");
103
var dll = Temp.CreateFile().
WriteAllText
("blah");
186
var f0 = Temp.CreateFile().
WriteAllText
("bogus").Path;
198
var doc = dir.CreateFile("a.xml").
WriteAllText
("<hello>");
225
var docInvariant = dir.CreateFile("a.xml").
WriteAllText
("Invariant");
226
var docGreek = dir.CreateDirectory(elGR.Name).CreateFile("a.xml").
WriteAllText
("Greek");
Microsoft.CodeAnalysis.Test.Utilities (1)
Metadata\IlasmUtilities.cs (1)
109
sourceFile.
WriteAllText
(completeIL);
Microsoft.CodeAnalysis.UnitTests (41)
Analyzers\AnalyzerFileReferenceTests.cs (4)
199
var textFile = directory.CreateFile("Goo.txt").
WriteAllText
("I am the very model of a modern major general.").Path;
231
var textFile = directory.CreateFile("Goo.txt").
WriteAllText
("I am the very model of a modern major general.").Path;
314
source.
WriteAllText
("int x = 0;");
343
source.
WriteAllText
("int x = 0;");
CommonCommandLineParserTests.cs (11)
35
file.
WriteAllText
(source);
40
newFile.
WriteAllText
(otherSources[i - 1]);
472
file.
WriteAllText
(source);
981
file.
WriteAllText
(source);
983
newFile.
WriteAllText
(source1);
1012
file.
WriteAllText
(source);
1046
file.
WriteAllText
(ruleSetSource);
1049
include.
WriteAllText
(includeSource);
1095
file.
WriteAllText
(ruleSetSource);
1098
include1.
WriteAllText
(includeSource1);
1101
include2.
WriteAllText
(includeSource2);
MetadataReferences\AssemblyIdentityComparerTests.cs (1)
616
var appConfig = Temp.CreateFile().
WriteAllText
(
MetadataReferences\AssemblyPortabilityPolicyTests.cs (25)
78
appConfig.
WriteAllText
("garbage");
84
appConfig.
WriteAllText
(
93
appConfig.
WriteAllText
(
115
appConfig.
WriteAllText
(
137
appConfig1.
WriteAllText
(
149
appConfig2.
WriteAllText
(
170
appConfig.
WriteAllText
(
178
appConfig.
WriteAllText
(
186
appConfig.
WriteAllText
(
196
appConfig.
WriteAllText
(
216
appConfig.
WriteAllText
(
235
appConfig.
WriteAllText
(
253
appConfig.
WriteAllText
(
270
appConfig.
WriteAllText
(
288
appConfig.
WriteAllText
(
307
appConfig.
WriteAllText
(
327
appConfig.
WriteAllText
(
351
appConfig.
WriteAllText
(
371
appConfig.
WriteAllText
(
387
var appConfig = Temp.CreateFile().
WriteAllText
(correctAppConfigText);
400
var appConfig = Temp.CreateFile().
WriteAllText
(correctAppConfigText);
407
appConfig.
WriteAllText
(correctAppConfigText);
412
appConfig = Temp.CreateFile().
WriteAllText
(correctAppConfigText);
417
appConfig.
WriteAllText
(@"
430
var appConfig2 = Temp.CreateFile().
WriteAllText
(correctAppConfigText);
Microsoft.CodeAnalysis.VisualBasic.CommandLine.UnitTests (178)
CommandLineBreakingChanges.vb (5)
16
Dim src As String = Temp.CreateFile().
WriteAllText
("
48
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
80
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
112
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
147
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
CommandLineIVTTests.vb (5)
25
Dim source2 = dir.CreateFile("B.vb").
WriteAllText
("
123
Dim source2 = dir.CreateFile("B.vb").
WriteAllText
("
224
Dim source2 = dir.CreateFile("B.vb").
WriteAllText
("
334
Dim source2 = dir.CreateFile("B.vb").
WriteAllText
("
453
Dim source3 = dir.CreateFile("C.vb").
WriteAllText
("
CommandLineTests.vb (161)
67
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
74
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
97
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
104
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
163
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
169
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
196
Dim src = dir.CreateFile("test.cs").
WriteAllText
("
206
Dim analyzerConfig1 = dir.CreateFile("analyzerconfig1").
WriteAllText
(configText)
207
Dim analyzerConfig2 = dir.CreateFile("analyzerconfig2").
WriteAllText
(configText)
230
Dim src = dir.CreateFile("temp.vb").
WriteAllText
("
253
Dim src = dir.CreateFile("temp.cs").
WriteAllText
("
283
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
326
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
348
Dim file = dir.CreateDirectory("Test Path (123)").CreateFile("hellovb.vb").
WriteAllText
(
385
file.
WriteAllText
(source)
404
file.
WriteAllText
(source)
423
file.
WriteAllText
(source)
467
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
508
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
526
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
544
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
585
Dim src As String = Temp.CreateFile().
WriteAllText
(<text>
751
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
776
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
919
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
1006
Dim source = Temp.CreateFile(prefix:="", extension:=".vb").
WriteAllText
("
2364
file1.
WriteAllText
("")
2365
file2.
WriteAllText
("")
2366
file3.
WriteAllText
("")
2367
file4.
WriteAllText
("")
2368
file5.
WriteAllText
("")
2412
file1.
WriteAllText
("")
2413
file2.
WriteAllText
("")
2414
file3.
WriteAllText
("")
2415
file4.
WriteAllText
("")
2416
file5.
WriteAllText
("")
2417
file6.
WriteAllText
("")
2600
file.
WriteAllText
(source)
2617
file.
WriteAllText
(source)
2790
file.
WriteAllText
(source)
3182
src.
WriteAllText
("
3189
sl.
WriteAllText
("{ ""documents"" : {} }")
3215
src.
WriteAllText
("
3222
sl.
WriteAllText
("{ ""documents"" : {} }")
3362
src.
WriteAllText
(embed_vb)
3363
src2.
WriteAllText
(embed2_vb)
3364
txt.
WriteAllText
(embed_xyz)
3618
file.
WriteAllText
(source)
3645
Dim src = dir.CreateFile("a.vb").
WriteAllText
(source.Value)
4134
xml.
WriteAllText
("EMPTY")
4186
xml.
WriteAllText
("EMPTY")
5012
src.
WriteAllText
("Imports System")
5034
src.
WriteAllText
("Imports System")
5051
src.
WriteAllText
("Imports System")
5373
file.
WriteAllText
("")
5905
file1.
WriteAllText
(source)
5957
file.
WriteAllText
(source.Value)
6010
file.
WriteAllText
(source.Value)
6097
file.
WriteAllText
(source.Value)
6141
file.
WriteAllText
(source.Value)
6189
file.
WriteAllText
(source.Value)
6235
file.
WriteAllText
(source.Value)
6277
file.
WriteAllText
(source.Value)
6312
file.
WriteAllText
(source.Value)
6344
file.
WriteAllText
(source.Value)
6378
file.
WriteAllText
(source.Value)
6412
file.
WriteAllText
(source.Value)
6444
file.
WriteAllText
(source.Value)
6886
Dim source As String = folder.CreateFile("src.vb").
WriteAllText
("").Path
6887
Dim ref As String = folder.CreateFile("ref.dll").
WriteAllText
("").Path
6911
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
6921
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
6960
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
6969
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
6994
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7003
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
7028
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7037
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
7062
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7066
Dim rsp As String = Temp.CreateFile().
WriteAllText
(<text>
7086
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7248
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7272
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7309
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7464
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
7614
Dim file = dir.CreateFile("a.vb").
WriteAllText
(source)
7671
file.
WriteAllText
(<![CDATA[
7735
file.
WriteAllText
("
7992
file.
WriteAllText
(source)
8025
file.
WriteAllText
(source)
8290
file.
WriteAllText
(source)
8312
file.
WriteAllText
(source)
8530
file.
WriteAllText
(source)
8606
file.
WriteAllText
(source)
8715
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8735
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8756
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8777
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8798
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8819
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8840
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8862
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8883
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8906
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8929
Dim ruleSetFile = dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
8950
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
9007
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
9030
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
9054
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
9075
Dim source As String = Temp.CreateFile().
WriteAllText
(<text>
9097
Dim source = dir.CreateFile("a.vb").
WriteAllText
(<text>
9102
Dim additionalFile = dir.CreateFile("AdditionalFile.txt").
WriteAllText
(<text>
9107
Dim nonCompilerInputFile = dir.CreateFile("DummyFile.txt").
WriteAllText
(<text>
9152
file.
WriteAllText
(source.Value)
9347
src.
WriteAllText
("
9423
src.
WriteAllText
(
9461
src.
WriteAllText
(
9567
sourceFile.
WriteAllText
(source.Value)
9737
Return Temp.CreateFile(directory:=directory, prefix:="", extension:=".vb").
WriteAllText
("
9747
Dim filePath = Temp.CreateFile().
WriteAllText
("").Path
9779
file.
WriteAllText
(source)
9823
file.
WriteAllText
(source)
9868
file.
WriteAllText
(source)
9893
file.
WriteAllText
(source)
9959
file.
WriteAllText
(source)
9997
file.
WriteAllText
(source)
10044
file.
WriteAllText
(source)
10050
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
10096
file.
WriteAllText
(source)
10145
file.
WriteAllText
(source)
10181
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10219
Dim src = dir.CreateFile("test.cs").
WriteAllText
("
10284
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10294
analyzerConfig = dir.CreateFile(".globalconfig").
WriteAllText
($"
10298
analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
($"
10331
Dim src = dir.CreateFile("temp.vb").
WriteAllText
("
10338
Dim globalConfig = dir.CreateFile(".globalconfig").
WriteAllText
("
10342
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
10364
Dim src = dir.CreateFile("temp.vb").
WriteAllText
("
10373
Dim globalConfig = dir.CreateFile(".globalconfig").
WriteAllText
($"
10386
dir.CreateFile("Rules.ruleset").
WriteAllText
(ruleSetSource)
10397
Dim src = dir.CreateFile("temp.vb").
WriteAllText
("
10404
Dim globalConfig = dir.CreateFile(".globalconfig").
WriteAllText
("
10420
srcFile.
WriteAllText
(source)
10424
additionalFile.
WriteAllText
(additionalText)
10499
Dim src = dir.CreateFile("temp.vb").
WriteAllText
(source)
10503
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
($"
10530
Dim src = directory.CreateFile("test.vb").
WriteAllText
("
10561
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10586
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10608
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10635
Dim src = dir.CreateFile("temp.vb").
WriteAllText
("
10698
Dim src = dir.CreateFile("temp.vb").
WriteAllText
("
10726
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10748
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
10771
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10793
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
10814
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10836
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
10860
Dim src = dir.CreateFile("test.vb").
WriteAllText
("
10884
Dim analyzerConfig = dir.CreateFile(".editorconfig").
WriteAllText
("
SarifErrorLoggerTests.vb (4)
47
Dim hello = Temp.CreateFile().
WriteAllText
(helloWorldVB).Path
82
Dim sourceFilePath = Temp.CreateFile().
WriteAllText
(source).Path
123
Dim sourceFilePath = Temp.CreateFile().
WriteAllText
(source).Path
161
Dim sourceFilePath = Temp.CreateFile().
WriteAllText
(source).Path
TouchedFileLoggingTests.vb (3)
34
Dim hello = Temp.CreateFile().
WriteAllText
(_helloWorldCS).Path
64
Dim hello = Temp.CreateFile().
WriteAllText
(_helloWorldCS).Path
99
Dim sourcePath = Temp.CreateFile().
WriteAllText
(
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (1)
WorkspaceTestBase.cs (1)
58
file.
WriteAllText
(s);
Microsoft.CodeAnalysis.Workspaces.UnitTests (3)
CommandLineProject\CommandLineProjectWorkspaceTests.cs (1)
24
tempFile.
WriteAllText
("class CSharpClass { }");
SolutionTests\SolutionTests.cs (2)
3306
file.
WriteAllText
(text2);
4505
var file = root.CreateFile(prefix: "massiveFile", extension: ".cs").
WriteAllText
("hello");
Microsoft.VisualStudio.LanguageServices.CSharp.UnitTests (12)
PersistentStorage\AbstractPersistentStorageTests.cs (3)
978
var solutionFile = persistentFolder.CreateOrOpenFile("Solution1.sln").
WriteAllText
("");
987
var projectFile = persistentFolder.CreateOrOpenFile("Project1.csproj").
WriteAllText
("");
992
var documentFile = persistentFolder.CreateOrOpenFile("Document1.cs").
WriteAllText
("");
ProjectSystemShim\CPS\AnalyzersTests.cs (2)
26
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
50
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
ProjectSystemShim\LegacyProject\AnalyzersTests.cs (7)
30
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
67
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
95
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
119
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
161
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
196
var ruleSetFile = Temp.CreateFile().
WriteAllText
(
232
var ruleSetFile = Temp.CreateFile().
WriteAllText
(ruleSetSource);
Roslyn.VisualStudio.Next.UnitTests (1)
Remote\SnapshotSerializationTests.cs (1)
568
tempCorlibXml.
WriteAllText
(@"<?xml version=""1.0"" encoding=""utf-8""?>
VBCSCompiler.UnitTests (17)
CompilerServerTests.cs (15)
115
file.
WriteAllText
(pair.Value);
223
var srcFile = tempDir.CreateFile("test.cs").
WriteAllText
(source).Path;
341
var srcFile = _tempDirectory.CreateFile("test.cs").
WriteAllText
("♕").Path;
363
var srcFile = _tempDirectory.CreateFile("test.vb").
WriteAllText
("♕").Path;
387
var srcFile = _tempDirectory.CreateFile("test.vb").
WriteAllText
("♕").Path;
1148
var srcFile = _tempDirectory.CreateFile("test.cs").
WriteAllText
("♕").Path;
1170
var srcFile = _tempDirectory.CreateFile("test.vb").
WriteAllText
(@"♕").Path;
1197
var srcFile = _tempDirectory.CreateFile("test.cs").
WriteAllText
("♕").Path;
1219
var srcFile = _tempDirectory.CreateFile("test.vb").
WriteAllText
(@"♕").Path;
1304
var srcFile = _tempDirectory.CreateFile("test.cs").
WriteAllText
("♕").Path;
1305
var rspFile = _tempDirectory.CreateFile("temp.rsp").
WriteAllText
(
1328
var srcFile = _tempDirectory.CreateFile("test.cs").
WriteAllText
("♕").Path;
1329
var rspFile = _tempDirectory.CreateFile("temp.rsp").
WriteAllText
(
1394
var srcFile = _tempDirectory.CreateFile("test.cs").
WriteAllText
("").Path;
1428
var srcFile = _tempDirectory.CreateFile("test.vb").
WriteAllText
("").Path;
TouchedFileLoggingTests.cs (2)
58
var source1 = Temp.CreateFile().
WriteAllText
(HelloWorldCS).Path;
109
var source1 = Temp.CreateFile().
WriteAllText
(HelloWorldVB).Path;