Beispiel #1
0
        public void FullTextConfigSerializeAnalyzerLuceneStandard()
        {
            StandardAnalyzer analyzer = new StandardAnalyzer(LuceneTestHarness.LuceneVersion);
            ConfigurationSerializationContext context = new ConfigurationSerializationContext();
            INode obj = context.Graph.CreateBlankNode();

            context.NextSubject = obj;
            analyzer.SerializeConfiguration(context);

            TestTools.ShowGraph(context.Graph);

            ConfigurationLoader.AutoConfigureObjectFactories(context.Graph);
            Object temp = ConfigurationLoader.LoadObject(context.Graph, obj);

            Assert.IsTrue(temp is StandardAnalyzer, "Should have returned a StandardAnalyzer instance");
            Assert.IsTrue(temp is Analyzer, "Should have returned a Analyzer instance");
        }