Andrew Onischuk created AMBARI-4339:
---------------------------------------
Summary: Create infrastructure for running unit tests of service
scripts
Key: AMBARI-4339
URL: https://issues.apache.org/jira/browse/AMBARI-4339
Project: Ambari
Issue Type: Bug
Reporter: Andrew Onischuk
Assignee: Andrew Onischuk
Fix For: 1.5.0
Attachments: AMBARI-4339.patch
As of now, we have no infrastructure for unit testing scripts inside stacks
folder. Under infrastructure, I mean:
- ambari-server pom changes (adding resorce management framework to the python
path of ambari-server)
- changes of unittests.py. As a possible approach: It should recursively
iterate over stacks folder, import script files from the stack and choose
appropriate test files from some another location. File structure of tests
folder may mimic file structure of stacks folder:
{code}
/ambari/ambari-server/src/test/python/stacks_test
├── 1.3.4
├── 2.0.8
│ ├── HBASE
│ └── HDFS
│ └── test_datanode.py
└── 2.1.1
{code}
The issue is, that scripts at different
stacks have same names, so we have to play around with manual imports and
different folders containing different tests for different stacks.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)