Home | History | Annotate | Download | only in cc
      1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 'use strict';
      6 
      7 base.require('cc.raster_task_slice_view');
      8 base.require('tracing.importer.trace_event_importer');
      9 base.require('tracing.trace_model');
     10 base.require('cc.layer_tree_host_impl_test_data');
     11 
     12 base.unittest.testSuite('cc.raster_task_slice_view', function() {
     13   test('instantiate', function() {
     14     var m = new tracing.TraceModel(g_catLTHIEvents);
     15     var p = m.processes[1];
     16 
     17     var rasterTask = p.threads[1].sliceGroup.slices.filter(function(slice) {
     18       return slice.title == 'TileManager::RunRasterTask';
     19     })[0];
     20 
     21     var view = new cc.RasterTaskSliceView();
     22     view.style.minHeight = '500px';
     23     view.slice = rasterTask;
     24     this.addHTMLOutput(view);
     25   });
     26 });
     27