7 <title>OPNFV presentation</title>
9 <meta name="description" content="Test API">
10 <meta name="author" content="Serena Feng">
12 <meta name="apple-mobile-web-app-capable" content="yes" />
13 <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
15 <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, minimal-ui">
17 <link rel="stylesheet" href="../css/reveal.css">
18 <link rel="stylesheet" href="../css/theme/OPNFV.css" id="theme">
20 <!-- Code syntax highlighting -->
21 <link rel="stylesheet" href="../lib/css/zenburn.css">
23 <!-- Printing and PDF exports -->
25 var link = document.createElement( 'link' );
26 link.rel = 'stylesheet';
27 link.type = 'text/css';
28 link.href = window.location.search.match( /print-pdf/gi ) ? '../css/print/pdf.css' : '../css/print/paper.css';
29 document.getElementsByTagName( 'head' )[0].appendChild( link );
33 <script src="lib/js/html5shiv.js"></script>
40 <!-- Any section element inside of this container is displayed as a slide -->
43 <section data-background="../img/title-bg.png" data-background-transition="none">
45 <h3>Clean, Easy, Complete</h3>
47 <h4>OPNFV testing community</h4>
48 <h5>OPNFV Design Summit, 20/6/2016, Berlin</h5>
52 <section data-markdown>
54 * A test API: what for?
60 <section data-markdown>
61 # A test API: what for?
63 <section data-markdown>
64 ## Give a consistant view for
67 * Test resources (Pods)
71 <section data-markdown>
72 ## Unify result display
74 * Many formats (log, html, json, ..)
75 * Many locations (in VM, Jumphost, external DB,...)
78 <section data-markdown>
86 <section data-markdown>
89 <section data-markdown>
92 * Simple data models aggreed with the testing group
94 * Wiki and rst documentation
97 <section data-markdown>
99 ![testapi](https://wiki.opnfv.org/download/attachments/2926452/results_collection_structure.png?version=1&modificationDate=1459196347000&api=v2 "OPNFV API page")
101 <section data-markdown>
102 ## API in Brahmaputra
103 ![testapi](../img/testapi0.png)
104 https://wiki.opnfv.org/display/functest/Collection+Of+Test+Results
107 <section data-markdown>
108 ## Lessons learned in B.
109 * Wiki documentation is painful
110 * result modl too simple
111 * version used for scenario
113 * no overall criteria (passed/failed)
114 * need unit tests for data model evolution
116 <section data-markdown>
117 ## Colorado refactoring
118 * done by Serena Feng (ZTE)
119 * update of the data model (based on lesson learned)
120 * creation of a swagger tornado framework for the doc
121 * creation of unit tests
126 <section data-markdown>
130 <h3>Test API evolution</h3>
142 <td>creation_date</td>
143 <td>start_date and stop_date</td>
147 <td>used as scenario</td>
153 <td>used for scenario</td>
156 <td>test_criteria</td>
158 <td>passed/failed</td>
161 <td>trust_indictator</td>
163 <td>between 0 and 1</td>
168 <td>get last N results</td>
173 <section data-markdown>
175 ![alt text](../img/testapi1.png "Test API swagger interface")
179 <pre><code class="hljs" data-trim contenteditable>
180 umry8364@umry8364-Latitude-E6400:~/Dev/OPNFV/releng/utils/test/result_collection_api$ ./run_test.sh
182 WARNING:tornado.general:404 GET /dashboard/v1/results?case=vPing&pod=zte-pod1&version=C&installer=fuel&period=5 (127.0.0.1): Project name missing
183 WARNING:tornado.access:404 GET /dashboard/v1/results?case=vPing&pod=zte-pod1&version=C&installer=fuel&period=5 (127.0.0.1) 2.30ms
184 WARNING:tornado.general:400 POST /api/v1/projects (127.0.0.1): name missing
186 WARNING:tornado.access:400 POST /api/v1/projects (127.0.0.1) 1.13ms
187 WARNING:tornado.access:403 PUT /api/v1/projects/functest/cases/vping_1 (127.0.0.1) 2.95ms
188 WARNING:tornado.general:404 PUT /api/v1/projects/functest/cases/notFound (127.0.0.1): {'project_name': u'functest', 'name': u'notFound'} could not be found in table [testcases]
189 WARNING:tornado.access:404 PUT /api/v1/projects/functest/cases/notFound (127.0.0.1) 2.85ms
191 Ran 74 tests in 1.848s
198 <img width="600" data-src="../img/colorado.png" alt="tests">
203 <img src="../img/logo-OPNFV.png" alt="OPNFV logo">
207 <script src="../lib/js/head.min.js"></script>
208 <script src="../js/reveal.js"></script>
212 // Full list of configuration options available at:
213 // https://github.com/hakimel/reveal.js#configuration
220 transition: 'slide', // none/fade/slide/convex/concave/zoom
222 // Optional reveal.js plugins
224 { src: '../lib/js/classList.js', condition: function() { return !document.body.classList; } },
225 { src: '../plugin/markdown/marked.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
226 { src: '../plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
227 { src: '../plugin/highlight/highlight.js', async: true, condition: function() { return !!document.querySelector( 'pre code' ); }, callback: function() { hljs.initHighlightingOnLoad(); } },
228 { src: '../plugin/zoom-js/zoom.js', async: true },
229 { src: '../plugin/notes/notes.js', async: true }