예제 #1
0
        public object Create()
        {
            if (_generator == null)
            {
                _generator = new LongText();
                _generator.Load();
            }

            return(_generator.Create(Length));
        }
예제 #2
0
        public void Generate_Starts_With_Text()
        {
            LongText g = new LongText();

            g.Load();
            string text = "";

            for (int i = 0; i < 100; i++)
            {
                var size = Sampling.GetUniform(140, 1000);
                text = g.Create(size, "super beggining of test");
                Console.WriteLine(String.Format("{0} ({1})\n", text, text.Length));
                Assert.True(text.Length <= size);
            }
        }