コード例 #1
0
ファイル: PnyxTest.cs プロジェクト: ericraider33/pnyx.net
        public void beforeAfterLine()
        {
            String actual;

            using (Pnyx p = new Pnyx())
            {
                p.readString(PLANETS_GODS);
                p.beforeAfterFilter(1, 1, pn => pn.grep("mercury", caseSensitive: false));
                actual = p.processToString();
            }

            const String expected =
                @"Cronus,Saturn,""Titan sky god, supreme ruler of the titans""
Hermes,Mercury,""Messenger of the gods, escort of souls to Hades""
Poseidon,Neptune,""God of the sea and earthquakes""
";

            Assert.Equal(expected, actual);
        }