ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Onischuk" <aonis...@hortonworks.com>
Subject Review Request 36691: Agent unit tests fail on trunk
Date Wed, 22 Jul 2015 12:17:04 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/36691/
-----------------------------------------------------------

Review request for Ambari and Dmitro Lisnichenko.


Bugs: AMBARI-12500
    https://issues.apache.org/jira/browse/AMBARI-12500


Repository: ambari


Description
-------

Looks like system call is not mocked properly  
Environment: Linux mint 17.1 (almost Ubuntu 14.04)

    
    
    
    ======================================================================
    FAIL: test_attribute_environment_non_root (TestExecuteResource.TestExecuteResource)
    ----------------------------------------------------------------------
    Traceback (most recent call last):
      File "/media/development/work/review_ambari/ambari-common/src/test/python/mock/mock.py",
line 1199, in patched
        return func(*args, **keywargs)
      File "/media/development/work/review_ambari/ambari-agent/src/test/python/resource_management/TestExecuteResource.py",
line 199, in test_attribute_environment_non_root
        self.assertEqual(popen_mock.call_args_list[0][0][0], expected_command)
    AssertionError: Lists differ: ['/bin/bash', '--login', '--no... != ['/bin/bash', '--login',
'--no...
    
    First differing element 4:
    ambari-sudo.sh su test_user -l -s /bin/bash -c 'export  PATH='"'"'/home/i/.pyenv/shims:/home/i/.pyenv/bin:/media/development/environment/alternatives/jdk7/bin:/media/development/environment/alternatives/maven31/bin:/home/i/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/media/development/work/irobot/snippets/bin/:~/.nvm/v0.10.31/bin/:~/.nvm/v0.10.31/lib/node_modules/brunch/bin/:/media/development/environment/android-sdk-linux/tools:/media/development/environment/android-sdk-linux/platform-tools:/home/i/bin:/media/development/environment/alternatives/scala/bin::/bin'"'"'
JAVA_HOME=/test/java/home ; echo "1"'
    ambari-sudo.sh su test_user -l -s /bin/bash -c 'export  PATH=/home/i/.pyenv/shims:/home/i/.pyenv/bin:/media/development/environment/alternatives/jdk7/bin:/media/development/environment/alternatives/maven31/bin:/home/i/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/media/development/work/irobot/snippets/bin/:~/.nvm/v0.10.31/bin/:~/.nvm/v0.10.31/lib/node_modules/brunch/bin/:/media/development/environment/android-sdk-linux/tools:/media/development/environment/android-sdk-linux/platform-tools:/home/i/bin:/media/development/environment/alternatives/scala/bin::/bin
JAVA_HOME=/test/java/home ; echo "1"'
    
    Diff is 2026 characters long. Set self.maxDiff to None to see it.
    
    ----------------------------------------------------------------------
    Ran 410 tests in 6.631s


Diffs
-----

  ambari-agent/src/test/python/resource_management/TestExecuteResource.py 04244e9 

Diff: https://reviews.apache.org/r/36691/diff/


Testing
-------

mvn clean test


Thanks,

Andrew Onischuk


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message