From 74c7067bffccd76f92dcbf51ba9211b9d6c6e533 Mon Sep 17 00:00:00 2001 From: chenjiankun Date: Sat, 24 Dec 2016 23:08:46 +0000 Subject: Create Test Reporting landing page JIRA: RELENG-165 In this patch, I do the follow things: 1.deploy tornado server(currently I haven't write any backend code, since the backend code depend on the testapi and I need to communicate with Serena). 2.landing page code(almostly finished. But I haven't the data, so for now, the data this page shows is a mock json. When the testapi and my backend code ready, this page will finally finished) 3.deployment: supervisor + nginx + tornado + angular usage: docker run -itd -p 8000:8000 opnfv/reporting: visit landing page: http://server_ip:8000/reporting/index.html test api: http://server_ip:8000/landing-page/filters visit old reporting page: http://server_ip:8000/display/master/yardstick/status-apex.html Change-Id: I527ab2661ce9e84b2942ebe673afbf5f2bc7878f Signed-off-by: chenjiankun --- reporting/pages/test/spec/controllers/main.js | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 reporting/pages/test/spec/controllers/main.js (limited to 'reporting/pages/test/spec/controllers') diff --git a/reporting/pages/test/spec/controllers/main.js b/reporting/pages/test/spec/controllers/main.js new file mode 100644 index 0000000..b92366d --- /dev/null +++ b/reporting/pages/test/spec/controllers/main.js @@ -0,0 +1,23 @@ +'use strict'; + +describe('Controller: MainCtrl', function () { + + // load the controller's module + beforeEach(module('opnfvApp')); + + var MainCtrl, + scope; + + // Initialize the controller and a mock scope + beforeEach(inject(function ($controller, $rootScope) { + scope = $rootScope.$new(); + MainCtrl = $controller('MainCtrl', { + $scope: scope + // place here mocked dependencies + }); + })); + + it('should attach a list of awesomeThings to the scope', function () { + expect(MainCtrl.awesomeThings.length).toBe(3); + }); +}); -- cgit 1.2.3-korg