Skip to content
  • yfriedman@chromium.org's avatar
    Normalize output path to cp.py · c9ba9b87
    yfriedman@chromium.org authored
    The js unit test targets have subtle dependencies on sources.
    Specifically, a rule pulls in js files and generates/runs js tests for
    them. This can be an issue with a relative path when the commands are
    run in parallel because a relative path may not exist. In this case, the
    rule for cr.js which is in ui depends on chrome. An easy way to repro
    this failure is:
    
    $ ninja -C out/Debug unit_tests
    $ rm -rf out/Debug/test_data
    $ ninja -C out/Debug test_data/chrome/../ui/webui/resources/js/cr.js
    
    Ninja is fine because it normalizes the path early enough whereas in
    python we relied on the system to compute the path but out/Debug/test_data/chrome may not exist
    
    BUG=235731
    
    Hat-tip to cjhopman for help debugging.
    
    Review URL: https://chromiumcodereview.appspot.com/14432003
    
    git-svn-id: svn://svn.chromium.org/chrome/trunk/src@197224 0039d316-1c4b-4281-b951-d872f2087c98
    c9ba9b87