11cb0ef41Sopenharmony_citest(function() { 21cb0ef41Sopenharmony_ci self.performance.mark("mark1"); 31cb0ef41Sopenharmony_ci self.performance.mark("mark2"); 41cb0ef41Sopenharmony_ci 51cb0ef41Sopenharmony_ci // test that two marks have been created 61cb0ef41Sopenharmony_ci var entries = self.performance.getEntriesByType("mark"); 71cb0ef41Sopenharmony_ci assert_equals(entries.length, 2, "Two marks have been created for this test."); 81cb0ef41Sopenharmony_ci 91cb0ef41Sopenharmony_ci // clear all marks 101cb0ef41Sopenharmony_ci self.performance.clearMarks(); 111cb0ef41Sopenharmony_ci 121cb0ef41Sopenharmony_ci // test that all marks were cleared 131cb0ef41Sopenharmony_ci entries = self.performance.getEntriesByType("mark"); 141cb0ef41Sopenharmony_ci 151cb0ef41Sopenharmony_ci assert_equals(entries.length, 0, "All marks have been cleared."); 161cb0ef41Sopenharmony_ci 171cb0ef41Sopenharmony_ci}, "Clearing all marks remove all of them."); 18