CFGLibTest.Unit.TestCFGToCNFEmptyProb.TestGetNullable08 C# (CSharp) Method

TestGetNullable08() private method

private TestGetNullable08 ( ) : void
return void
		public void TestGetNullable08() {
			var productions = new HashSet<Production> {
				CFGParser.Production("<S> -> 'x'"),
				CFGParser.Production("<S> -> ε"),
				CFGParser.Production("<S> -> <S> <S> <S>"),
			};

			var result = (Dictionary<Nonterminal, double>)nullableClass.InvokeStatic("GetNullable", new object[] { productions });

			Assert.IsTrue(result.Count == 1);
			Helpers.AssertNear(0.34729635533386069770343325353862959, result[Nonterminal.Of("S")]);
		}