Skip to content

Commit 729c56c

Browse files
committed
demo dumps
1 parent 519278f commit 729c56c

File tree

1 file changed

+49
-7
lines changed

1 file changed

+49
-7
lines changed

Program.vb

Lines changed: 49 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,58 @@
22

33
Module Program
44

5-
Sub Main()
5+
Sub Main()
66

7-
Dim dlTest = New Tests.DumpingAndLoging()
8-
dlTest.TestAll()
7+
Program._demoDumpAndLog()
8+
Program._demoException()
9+
'Program._runTests()
910

10-
Dim eTest = New Tests.ExceptionsRendering()
11-
eTest.TestAll()
11+
Console.ReadLine()
12+
End Sub
1213

13-
Console.ReadLine()
14+
Private Sub _demoDumpAndLog()
15+
Console.Write("Press enter key to dump demo data and write it to HDD.")
16+
Console.ReadLine()
17+
Dim demoObject = New Dictionary(Of String, Object)() From {
18+
{"clark", New With {
19+
.name = "Clark",
20+
.surname = "Kent",
21+
.tshirtIdol = "chuck"
22+
}},
23+
{"chuck", New With {
24+
.name = "Chuck",
25+
.surname = "Noris",
26+
.tshirtIdol = "bud"
27+
}},
28+
{"bud", New With {
29+
.name = "Bud",
30+
.surname = "Spencer",
31+
.tshirtIdol = ""
32+
}}
33+
}
34+
Debug.Dump(demoObject)
35+
Debug.Log(demoObject)
36+
End Sub
1437

15-
End Sub
38+
Private Sub _demoException()
39+
Console.Write("Press enter key to dump catched demo exception and write it to HDD.")
40+
Console.ReadLine()
41+
42+
Try
43+
Throw New Exception("Demo exception:-)")
44+
Catch ex As Exception
45+
Debug.Dump(ex)
46+
Debug.Log(ex)
47+
End Try
48+
End Sub
49+
50+
Private Sub _runTests()
51+
Console.Write("Pres enter key to start duping test objects.")
52+
Console.ReadLine()
53+
Dim dlTest = New Tests.DumpingAndLoging()
54+
dlTest.TestAll()
55+
Dim eTest = New Tests.ExceptionsRendering()
56+
eTest.TestAll()
57+
End Sub
1658

1759
End Module

0 commit comments

Comments
 (0)