aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit
AgeCommit message (Collapse)AuthorFilesLines
2017-04-14Merge "User friendly messages for exceptions"zhihui wu3-0/+9
2017-04-13User friendly messages for exceptionsTaseer3-0/+9
- Use colorama for color - Implement verbosity option in separate patch Change-Id: Ib2491d867e9bbf59cb00874d99a11f86ad7eea1b Signed-off-by: Taseer Ahmed <taseer94@gmail.com>
2017-04-10Implement calculator PoCYujun Zhang1-0/+85
- use `mean` as default formula Change-Id: I236b46c1e52f3535fb6e954d324790b1421126bd Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-04-06Add ansible action plugin `collect`Yujun Zhang1-0/+36
- this plugin collects information or metrics from string - it is reworked from qtip.collector.parser.grep - the captured subgroups are always list even only one match found Change-Id: I1def3d7b40c7928b503fae1be531976a13e5d0be Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-04-06Add ansible module `fuel`Yujun Zhang1-0/+60
This module will be used to generate a dynamic inventory of fuel nodes for performance testing Change-Id: Idaa491c5fc3050abfb8ba36328f2113cf2885179 Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-04-03Beautify compute reportTaseer2-71/+48
Change-Id: I0c4faa3720d980970f923697c879627ccbf22852 Signed-off-by: Taseer Ahmed <taseer94@gmail.com>
2017-03-29Add jinja2 filter justifyYujun Zhang1-0/+19
It will be used in report template Change-Id: I69fd891db5e69b2dec441bd296836e6806461b78 Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-03-24Merge "Integrate cli, runner and reporter."zhihui wu2-24/+40
2017-03-23Integrate cli, runner and reporter.Taseer2-24/+40
- Execute runner via a shell command - Change format of qtip result directory to qtip-timestamp - Add path option in reporter to match with runner JIRA: QTIP-229 Change-Id: I7d8562fd7100b1f40cdc8d53b0daa6a06a55b495 Signed-off-by: Taseer Ahmed <taseer94@gmail.com>
2017-03-22Add unit tests for List and get in API.akhilbatra8984-0/+151
- refactor controllers - remove abspath and other irrelvant data in response - move fixtures - refactor decorators JIRA: QTIP-226 Change-Id: I5fac5b1bc998da198098992e7ddb47ba49685f31 Signed-off-by: akhilbatra898 <akhil.batra@research.iiit.ac.in>
2017-03-20Merge "Refactor reporter module"zhihui wu3-39/+157
2017-03-18Refactor reporter moduleTaseer3-39/+157
- Create templates for report format specific to each metric. - Outputs the details of the specified metric across all the nodes in cluster. - Timeline to be covered in a separate patch JIRA: QTIP-199 Change-Id: Ic83749725b0c9cc5bd9a7f24f21b2cd113abe0e1 Signed-off-by: Taseer Ahmed <taseer94@gmail.com>
2017-03-16Merge "Implement 'show' command."Yujun Zhang3-6/+10
2017-03-14Implement 'show' command.Taseer3-6/+10
- Render the description via templates JIRA: QTIP-205 Change-Id: I10523f85f80350e901a4a701bb65ca4833f8ff7c Signed-off-by: Taseer Ahmed <taseer94@gmail.com>
2017-03-13optimize console infowu.zhihui1-21/+5
- use QtipLogger instead of print - delete useless print Change-Id: I1e08382a5d78ce53cf455496363bce3762b81dd2 Signed-off-by: wu.zhihui <wu.zhihui1@zte.com.cn>
2017-03-10Implement 'list' command.Taseer3-8/+10
- Loads Qtip components from the default path. JIRA: QTIP-205 Change-Id: Id87993d65c5cd6a23c199cf1049d75a0971b6354 Signed-off-by: Taseer Ahmed <taseer94@gmail.com>
2017-03-07Merge "rework env.py"zhihui wu1-34/+263
2017-03-07Merge "Implement debug option"Yujun Zhang1-4/+5
2017-03-07Merge "Implement reporter module."Yujun Zhang2-6/+39
2017-03-04rework env.pywu.zhihui1-34/+263
Create a new class AnsibleEnvSetup for setuping test environment for ansible driver. Change-Id: I5d2385b33e5666acb7bbac1a6d960a805d846a32 Signed-off-by: wu.zhihui <wu.zhihui1@zte.com.cn>
2017-03-04Implement debug optionTaseer Ahmed1-4/+5
Show traceback only when debug flag specified. JIRA: QTIP-201 Change-Id: I9cc4b4ed5a2cb2d2efabd9c0eb3aac216321ebac Signed-off-by: Taseer Ahmed <taseer94@gmail.com>
2017-03-03Implement reporter module.Taseer Ahmed2-6/+39
- Add cli module - Implement timeline outline JIRA: QTIP-199 Signed-off-by: Taseer Ahmed <taseer94@gmail.com> Change-Id: I487b76123a785731c356143d1ae7f3123c11f398
2017-03-03Add missing license headersYujun Zhang1-0/+9
Change-Id: I33cdd3b1304c695b81d2e23434a70acfcc9a21f8 Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-03-01Merge "refactor code related with setup env"zhihui wu1-0/+94
2017-02-28refactor code related with setup envwu.zhihui1-0/+94
- modify env.py and scripts - add unit test Change-Id: I416cd517bdddfeb907675705009d83ecada7f87c Signed-off-by: wu.zhihui <wu.zhihui1@zte.com.cn>
2017-02-27Rename test case to avoid possible name conflictYujun Zhang1-0/+0
pytest does not allow two test file have same name despite they are in different folder. Change-Id: I568fe042f6dbe99df336d0ce4d6ed9c78305fe74 Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-27Merge "Fix bug when no paths is given for Plan constructor"Yujun Zhang1-7/+10
2017-02-27Merge "Add reporter PoC"Yujun Zhang1-0/+29
2017-02-27Merge "Refactoring qtip.runner"Yujun Zhang1-0/+16
2017-02-24Fix bug when no paths is given for Plan constructorYujun Zhang1-7/+10
FileLoader was trying to initialize abspath by finding a matched name from abspath which will lead to an exception. Use default paths of class instead. Change-Id: I8ca2122e97edd734aa68b4c6b12196960842313b Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-23Merge "Addition of detail viewing command."Yujun Zhang3-3/+27
2017-02-23Merge "add logger's unittest"Yujun Zhang2-0/+48
2017-02-22add logger's unittestSerenaFeng2-0/+48
Change-Id: I9a7d3c6afeff5432017f5bfd4a961a719c93c086 Signed-off-by: SerenaFeng <feng.xiaowei@zte.com.cn>
2017-02-22Add reporter PoCYujun Zhang1-0/+29
Change-Id: I5134a0d95d75fcb3a75267a5f20b4ace8638156a Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-22Refactoring qtip.runnerYujun Zhang1-0/+16
- deprecate current PoC - cover it with test Change-Id: Ia1a43c195781fdd09e7d925ed3bf4509f226916f Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-22Merge "Refactoring qtip.base.error"Yujun Zhang3-2/+82
2017-02-22Addition of detail viewing command.Taseer Ahmed3-3/+27
Change-Id: Ia9ad825f20b279db1852587540a2ad6cb3815e1d Signed-off-by:Taseer Ahmed <taseer94@gmail.com>
2017-02-21Refactoring qtip.base.errorYujun Zhang3-2/+82
- move method make_tbd to qtip.util.dev - add suffix Error to follow the Python naming convention - rename arguments of NotFoundError to make it generic Change-Id: I81e406b7fa10c3b40004434f6a9c2e7bbf7603ee Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-21Implement the collector regex for system info logfile.wu.zhihui1-1/+1
I commented sone lines. Because these part can't be supported well by grep_in_file(). Change-Id: Ifc0ab1b6f40180e40c150b2c80eeaa6c72274ac9 Signed-off-by: wu.zhihui <wu.zhihui1@zte.com.cn>
2017-02-21support multi-line search in grep parserwu.zhihui1-1/+3
use finditer with multiline mode JIRA: QTIP-211 Change-Id: Ib8854f749a0258f6b6775be9b80573f6ac8e47db Signed-off-by: wu.zhihui <wu.zhihui1@zte.com.cn>
2017-02-19Fix error in loader testYujun Zhang3-10/+6
Change-Id: Idac7d0ec77941974a5f93108fd5f450eef05a5ad Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-19Clean up tests folderYujun Zhang9-0/+0
- remove __init__.py as recommended in pytest docs[1] - rename cli test files for a consistent naming style - remove empty test files [1]: http://docs.pytest.org/en/latest/goodpractices.html#choosing-a-test-layout-import-rules Change-Id: Idfb5d8a8fb7a590ef988a761991b8e313089e9bc Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-15Implement logfile collector and grep parserYujun Zhang5-2/+90
JIRA: QTIP-207 JIRA: QTIP-208 Change-Id: Icc14d3097fb305e59df716636ef87504490c9d1b Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-15Refactoring collector initialization in plan loaderYujun Zhang1-2/+3
- move ClassProps to module - collectors should be array in plan definition Change-Id: I37d85dbc977c91aa1bb81de45b5e1c41660e6d1f Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-15Add test for yaml_file loaderYujun Zhang1-0/+33
Change-Id: I997ceeed17bd35889f6b0f3465bbe75df256b71e Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-07Add unit test for BaseTransformerYujun Zhang2-0/+15
Change-Id: Ia379af759d9442f5b53f5052682e6218acef8a1b Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-02-05Fix bug that metric test is not collectedYujun Zhang1-4/+4
Change-Id: I2e05891a89745712274757ba9af928b03fb5edf6 Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-01-29Refactor loader classesYujun Zhang1-1/+1
- rename BaseLoader to YamlFileLoader as base class of QTIP specs loader - create an abstract BaseLoader - create FileLoader for logfile collector Change-Id: I0c992cd847fc0dce4fdd73a13c1cdbc406c84532 Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-01-25Merge "Click's built in support for version option"zhihui wu1-1/+1
2017-01-25Merge "Small corrections"zhihui wu1-3/+6