예제 #1
0
        //[assembly: Obfuscation(Exclude = true, Feature = "control flow protection: true")]
        public static void Main(string[] args)
        {
            args_in = args;

            Program p = new Program();

            LoopTests.RunLoopTests();
            BasicTests.RunBasicTests();
            ExceptionTests.RunExceptionTests();
            BranchTests.RunBranchTests();
            FieldTests.RunFieldTests();
            ExtensionsTests.RunExtenstionTests();
            LambdaTests.RunLambdaTests();
            DelegatesTests.RunDelegatesTests();
            FileOperations.RunReadFileTests();
            CodeBasicTests.RunBasicTests();
            CodeBranchTests.RunBranchTests();
            CodeLoopTests.RunLoopTests();

            PerformanceTests.RunLoopTests();

            BasicOperations.RunBasicTests();

            TraceLoopTests.RunLoopTests();

            ConditionalExpressionTests.RunBasicTests();

            TestReport();
            Console.ReadKey();
        }
예제 #2
0
        public static void DeserializeJsonAsync()
        {
            PerformanceTests t = new PerformanceTests();

            t.Iterations = 50000;
            t.DeserializeAsync().Wait();
        }
        public ActionResult Index()
        {
            var performanceTests = new PerformanceTests();
            PerformanceTestsResults testsResults = performanceTests.RunTests();

            return(View(testsResults));
        }
예제 #4
0
 static void Main(string[] args)
 {
     var test = new PerformanceTests();
     const int iterations = 500;
     Console.WriteLine("Running {0} iterations that load up a post entity", iterations);
     test.Run(iterations);
 }
예제 #5
0
        // ReSharper disable once UnusedParameter.Local
        private static void Main(string[] args)
        {

            var seconds = 20;
            Console.WriteLine("Begin performance testing; {0} seconds each async/sync…", seconds);
            Console.WriteLine(); 
            _tests = SetupTests();
            long asyncAggregate=0;
            long syncAggregate = 0;
            long timestampAggregate = 0;
            // get some initialization out of the way:
            RunAsyncTest(5);
            Console.Clear();
            var includeTimestampTests = args.Length > 0 && args[0].ToUpper() == "T";
            int i;
            for (i = 0; i < 3; i++)
            {
                if(includeTimestampTests)
                    timestampAggregate += RunTimestampTest(seconds);
                asyncAggregate += RunAsyncTest(seconds);
                syncAggregate += RunSyncTest(seconds);
            }
            if (includeTimestampTests)
                Console.WriteLine("\r\nTimestamp avg: {0:n0}/s", timestampAggregate / i);
            Console.WriteLine("\r\nAsync average: {0:n0}/s", asyncAggregate / i);
            Console.WriteLine("\r\n Sync average: {0:n0}/s", syncAggregate / i);

            Console.WriteLine("\r\n");
            PromptKey("Press any key to exit... ");
        }
예제 #6
0
        public static void DeserializeJson()
        {
            PerformanceTests t = new PerformanceTests();

            t.Iterations = 50000;
            t.Deserialize();
        }
예제 #7
0
        public static void TokenWriteToAsync()
        {
            PerformanceTests t = new PerformanceTests();

            t.Iterations = 50000;
            t.TokenWriteToAsync().Wait();
        }
예제 #8
0
 public void Start()
 {
     m_Tests = new PerformanceTests {
         RuntimeLog = Path.Combine(Application.dataPath, logFile)
     };
     m_Tests.BeforeAll();
     m_StartFrame = Time.frameCount;
 }
예제 #9
0
 public static void Main(string[] args)
 {
     var perfTests = new PerformanceTests();
     var transportTest = new Transports();
      transportTest.custom_transport_test();
     // transportTest.zmq_transport_test();
     //  perfTests.should_send_messages();
 }
		static void Performance ()
		{
			const int iterations = 20;
			var test = new PerformanceTests ();
			Console.WriteLine ("Running {0} iterations that load up a post entity", iterations);
			test.Run (iterations);
			Console.WriteLine ("Finish...");
		}
예제 #11
0
 public static void Main(String[] args)
 {
     RegTestExpression.Start();
     RegTestExpressionV2.Start();
     RegTestExpressionAPI.Start();
     RegTestSyntax.Start();
     PerformanceTests.Start();
 }
예제 #12
0
        static void Main(string[] args)
        {
            Console.WriteLine("Press enter to start");
            Console.ReadLine();

            Test.PerformanceTests t = new PerformanceTests();
            t.NormalFencePerfTest();

            Console.ReadLine();
        }
예제 #13
0
 private static void Main()
 {
     using (var performanceTests = new PerformanceTests())
     {
         //performanceTests.OpenAppendedFileWPF();
         //performanceTests.OpenAppendedFileAvaloniaNet();
         //performanceTests.OpenAppendedFileAvaloniaNetCore();
         //performanceTests.OpenAppendedFileUwp();
         performanceTests.OpenAppendedFileAllPlatforms();
     }
 }
예제 #14
0
파일: Program.cs 프로젝트: oryacobi/Jcob
        static void Main()
        {
            PerformanceTests test  = new PerformanceTests();
            var performanceResults = test.Run();

            foreach (PerformanceTests.PerformanceResults result in performanceResults)
            {
                Console.WriteLine(result);
            }

            Console.ReadLine();
        }
예제 #15
0
        public static void Main(String[] args)
        {
            //Thread T1 = new Thread(RegTestExpression.Start, 536870912);
            //T1.Start();
            //Thread T2 = new Thread(RegTestExpressionV2.Start, 536870912);
            //T2.Start();
            //Thread T3 = new Thread(RegTestExpressionAPI.Start);
            //T3.Start();
            //Thread T5 = new Thread(RegTestSyntax.Start);
            //T5.Start();

            PerformanceTests.Start();
        }
예제 #16
0
        static void Main(string[] args)
        {
            var tests = new PerformanceTests();

            tests.RandomTests();
            tests.SortedTests();
            tests.ReversedTests();

            tests.RandomTests_List();
            tests.SortedTests_List();
            tests.ReversedTests_List();

            //tests.RandomTests_ListWithMergeBack();
        }
예제 #17
0
    static void Main(string[] args)
    {
        //UnitTesting.testAlphaBeta();
        //UnitTesting.testHeuristicA();
        //UnitTesting.testHeuristicAGood(1000, Pentago_Rules.EvaluationFunction.controlHeuristic, 4, Pentago_Rules.EvaluationFunction.heuristicA, 4, UnitTesting.testSecond, false, false);
        //Pentago1P.play();

        //UnitTesting.testMinMax();
        //UnitTesting.test_auxiliar_methods();
        //UnitTesting.testGenerateNewBoard();
        PerformanceTests.testPerformnace(5);
        //PentagoPandora.BUILD_PANDORA();
        //Console.WriteLine("---ENDED---")
    }
        public void RunPerformanceTests()
        {
            EnsureDBSetup();
            var       test       = new PerformanceTests();
            const int iterations = 500;

            Console.WriteLine("Running {0} iterations that load up a post entity", iterations);

            Console.WriteLine("\n\n Run 1:\n");
            test.Run(iterations);
            Console.WriteLine("\n\n Run 2:\n");
            test.Run(iterations);
            Console.WriteLine("\n\n Run 3:\n");
            test.Run(iterations);
        }
        static async Task Main(string[] args)
        {
            Log.StartSession(LoadConfig());

            try
            {
                var logTests = new LogTests();
                logTests.WriteMessagesForOrderTesting();
                logTests.BetterLogSample();
                logTests.WriteException();
                logTests.WriteExceptionAttributedMessages();

                var testFixture = new PerformanceTests();

                System.Console.WriteLine("Running first test round");
                testFixture.AsyncMessage();
                Log.EndFile("Rolling over test file (First time)");


                System.Console.WriteLine("Running second test round");
                testFixture.AsyncMessage();
                Log.EndFile("Rolling over test file (Second time)");


                System.Console.WriteLine("Running third test round");
                testFixture.AsyncMessage();
                Log.EndFile("Rolling over test file (Third time)");


                System.Console.WriteLine("Sending new sessions to server...");
                await Log.SendSessions(SessionCriteria.NewSessions);

                System.Console.WriteLine("Completed sending to server.");
            }
            catch (Exception ex)
            {
                Log.RecordException(ex, "Main", false);
                Log.EndSession(SessionStatus.Crashed, "Exiting due to unhandled exception");
            }
            finally
            {
                Log.EndSession(SessionStatus.Normal, "Exiting test application");
            }
        }
예제 #20
0
    public static List <PerformanceTest> getTests()
    {
        List <PerformanceTest> result = new List <PerformanceTest>();

        string testString = "abcde12345";

        void addTests()
        {
            PerformanceTests.getTestsFromClassByReflection(new PInvokeStringTests(testString)).ForEach(test => {
                test.category = $"String tests (length {testString.Length})";
                result.Add(test);
            });
        }

        addTests();
        testString = string.Concat(Enumerable.Repeat(testString, 100));
        addTests();

        return(result);
    }
예제 #21
0
 public static void DeserializeLargeJson()
 {
     PerformanceTests t = new PerformanceTests();
     t.DeserializeLargeJson();
 }
예제 #22
0
        public static void DeserializeLargeJson()
        {
            PerformanceTests t = new PerformanceTests();

            t.DeserializeLargeJson();
        }
예제 #23
0
 public static void DeserializeJson()
 {
     PerformanceTests t = new PerformanceTests();
     t.Iterations = 50000;
     t.Deserialize();
 }
예제 #24
0
		private static void RunPerformanceTests()
		{
			var test = new PerformanceTests();
			Console.WriteLine("Running 500 itrations that load up a post entity");
			test.Run(500);
		}
예제 #25
0
	public static List<PerformanceTest> getTests() {
		return PerformanceTests.getTestsFromClassByReflection(new PInvokeTests()).Select(test => {
			test.category = $"PInvoke tests";
			return test;
		}).ToList();
	}
예제 #26
0
 private static PerformanceTests SetupTests()
 {
     _generator = new Base36IdGenerator(11, 4, 5, null, "-", new[] {15, 10, 5});
     var tests = new PerformanceTests(_generator);
     return tests;
 }
예제 #27
0
        public static void ValidateJson()
        {
            PerformanceTests t = new PerformanceTests();

            t.IsValid_SchemaSpec();
        }
예제 #28
0
        public static void ValidateJson()
        {
            PerformanceTests t = new PerformanceTests();

            t.ReaderPerformance();
        }
예제 #29
0
        public static void ValidateJson()
        {
            PerformanceTests t = new PerformanceTests();

            t.IsValidPerformance_Failure();
        }
예제 #30
0
        public static void ValidateJson()
        {
            PerformanceTests t = new PerformanceTests();

            t.DeeplyNestedConditionalScopes();
        }