2 // Microsoft.VisualBasic.* Test Cases
5 // Jochen Wezel (jwezel@compumaster.de)
7 // Based on the C# units of
8 // Erik LeBel (eriklebel@yahoo.ca)
10 // (c) 2003 Jochen Wezel, CompuMaster GmbH
16 using System.CodeDom.Compiler;
17 using Microsoft.VisualBasic;
19 using NUnit.Framework;
21 namespace MonoTests.Microsoft.VisualBasic
25 /// Base test for a variety of CodeGenerator GenerateCodeXXX methods.
27 /// This testing is a form of hybrid test, it tests the variety of CodeDom
28 /// classes as well as the VB code generator.
30 /// The implementations bellow provide a template as well as guidlines for
31 /// implementing further tests.
34 public abstract class CodeGeneratorTestBase
36 CodeDomProvider provider = null;
37 protected ICodeGenerator generator = null;
38 protected CodeGeneratorOptions options = null;
40 public void InitBase()
42 provider = new VBCodeProvider ();
43 generator = provider.CreateGenerator ();
44 options = new CodeGeneratorOptions ();
47 protected string Generate ()
49 return Generate (options);
52 protected virtual string NewLine
57 protected abstract string Generate (CodeGeneratorOptions options);