コード例 #1
0
 public void RunTests(BenchmarkTest[] tests)
 {
     logger = new BenchmarkLogger("BenchmarkRun");
     logger.Print("benchmark-date> " + DateTime.Now);
     logger.Print("benchmark-device-model> " + SystemInfo.deviceModel);
     IsRunning        = true;
     this.tests       = tests;
     currentTestIndex = 0;
     runNextTest();
 }
コード例 #2
0
 private bool onRuntimeProfileStart(BenchmarkRuntimeProfileEvents.RuntimeProfileStart startEvent)
 {
     profiling    = true;
     pollRate     = startEvent.PollRate;
     memProfiling = startEvent.PollMemory;
     frameCount   = 0;
     Disney.Kelowna.Common.Performance performance = Service.Get <Disney.Kelowna.Common.Performance>();
     performance.AutomaticMemorySampling = false;
     performance.ResetMetrics();
     logger.Print("Runtime Profiling Starting. Profiling Memory = " + memProfiling);
     return(false);
 }
コード例 #3
0
        private void onFinish(int exitStatus = 0)
        {
            logger.Print("benchmark-exit-status> " + exitStatus);
            logger.Dispose();
            IsRunning = false;
            Scene sceneByPath = SceneManager.GetSceneByPath("Assets/Game/Core/Tests/BenchmarkingTests/Scenes/EmptyScene.unity");

            if (sceneByPath.buildIndex >= 0)
            {
                SceneManager.LoadScene(sceneByPath.buildIndex);
            }
        }