TRD-0006 Restructure the folder layout
This commit is contained in:
30
AxiomUnitTestProject/ScannerTests.cs
Normal file
30
AxiomUnitTestProject/ScannerTests.cs
Normal file
@@ -0,0 +1,30 @@
|
||||
using System;
|
||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||
using System.Collections.Generic;
|
||||
using Axiom.Utils;
|
||||
using Axiom.Interpreter;
|
||||
using System.IO;
|
||||
|
||||
namespace AxiomUnitTestProject
|
||||
{
|
||||
[TestClass]
|
||||
public class ScannerTests
|
||||
{
|
||||
[TestMethod]
|
||||
public void ScannerShouldScan()
|
||||
{
|
||||
List<String> codeLines = TestData.CodeLines();
|
||||
foreach(String expression in codeLines)
|
||||
{
|
||||
BinaryWriter binaryWriter=new BinaryWriter(new MemoryStream());
|
||||
SymbolTable symbolTable = new SymbolTable();
|
||||
BinaryReader binaryReader = null;
|
||||
binaryReader = new BinaryReader(Utility.StreamFromString(expression));
|
||||
Scanner scanner = new Scanner(binaryReader, binaryWriter, symbolTable);
|
||||
Console.WriteLine("Expression:\""+expression+"\"");
|
||||
Assert.IsTrue(scanner.Analyze());
|
||||
Console.WriteLine("**************************");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user