Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel de Icaza <miguel@gnome.org>2001-12-04 03:54:29 +0300
committerMiguel de Icaza <miguel@gnome.org>2001-12-04 03:54:29 +0300
commit9b240f5e20ba55cecf41848bbabd59f8329443c3 (patch)
tree1d35f75aa69536533378b478584664c71db3af82 /mcs/tests/test-51.cs
parentc736b252ac8f644d27efeb8346fc103689ed5109 (diff)
Add new tests
svn path=/trunk/mcs/; revision=1516
Diffstat (limited to 'mcs/tests/test-51.cs')
-rwxr-xr-xmcs/tests/test-51.cs55
1 files changed, 55 insertions, 0 deletions
diff --git a/mcs/tests/test-51.cs b/mcs/tests/test-51.cs
new file mode 100755
index 00000000000..25dfd36c950
--- /dev/null
+++ b/mcs/tests/test-51.cs
@@ -0,0 +1,55 @@
+//
+// This test is used to test the `base' implementation
+//
+using System;
+
+class Base {
+ public int b_int_field;
+ string b_string_field;
+
+ const int b_const_three = 3;
+
+ int b_int_property {
+ get {
+ return b_int_field;
+ }
+
+ set {
+ b_int_field = value;
+ }
+ }
+
+ string b_get_id ()
+ {
+ return "Base";
+ }
+
+ public Base ()
+ {
+ b_int_field = 1;
+ b_string_field = "string";
+ }
+}
+
+class Derived : Base {
+ int b_int_field;
+
+ public Derived ()
+ {
+ b_int_field = 10;
+ }
+
+ void Test ()
+ {
+ Console.WriteLine (" int field: " + b_int_field);
+ Console.WriteLine ("base int field: " + base.b_int_field);
+ }
+}
+
+class boot {
+ static int Main ()
+ {
+ Derived d = new Derived ();
+ return 0;
+ }
+}