Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a0511081 authored by Tim Murray's avatar Tim Murray Committed by Android (Google) Code Review
Browse files

Merge "Add loop option to hwuitest." into mnc-dev

parents 9260cb7f 1a0f1c7c
Loading
Loading
Loading
Loading
+14 −1
Original line number Diff line number Diff line
@@ -263,7 +263,20 @@ int main(int argc, char* argv[]) {
        printf("Error: couldn't find test %s\n", testName);
        return 1;
    }
    int loopCount = 1;
    if (argc > 2) {
        loopCount = atoi(argv[2]);
        if (!loopCount) {
            printf("Invalid loop count!\n");
            return 1;
        }
    }
    if (loopCount < 0) {
        loopCount = INT_MAX;
    }
    for (int i = 0; i < loopCount; i++) {
        proc();
    }
    printf("Success!\n");
    return 0;
}