~doanac/phablet-tools/cmd-run

« back to all changes in this revision

Viewing changes to phablet-test-run

  • Committer: Tarmac
  • Author(s): Michael Zanetti
  • Date: 2013-05-06 21:36:34 UTC
  • mfrom: (86.2.1 phablet-tools)
  • Revision ID: tarmac-20130506213634-gcw0pm602xisudtw
fix installation of multiple local packages.

Approved by Sergio Schvezov, PS Jenkins bot.

Show diffs side-by-side

added added

removed removed

Lines of Context:
72
72
 
73
73
install_packages() {
74
74
 
75
 
    if test -n $TESTPACKAGES; then
 
75
    if test -n "$TESTPACKAGES"; then
76
76
        exec_with_adb apt-get -y -q install $TESTPACKAGES
77
77
    fi
78
78
 
79
 
    if test -n $LOCALPACKAGES; then
 
79
    if test -n "$LOCALPACKAGES"; then
80
80
        exec_with_adb mkdir -p /tmp/phablet-run-test/
81
81
        exec_with_adb rm -rf /tmp/phablet-run-test/*
 
82
        PACKAGELIST=""
82
83
        for PACKAGEPATH in $LOCALPACKAGES; do
83
84
            PACKAGE=$(basename $PACKAGEPATH)
84
85
            echo "Pushing $PACKAGE..."
85
86
            adb push $PACKAGEPATH /data/ubuntu/tmp/phablet-run-test/
86
 
            exec_with_adb dpkg -i /tmp/phablet-run-test/$PACKAGE
 
87
            PACKAGELIST="$PACKAGELIST /tmp/phablet-run-test/$PACKAGE"
87
88
        done
 
89
        exec_with_adb dpkg -i $PACKAGELIST
88
90
    fi
89
91
}
90
92