Lines Matching full:tests
132 } tests[] = {
144 fprintf(stderr,"usage: usbtest <testname>\n\navailable tests:\n");
145 for(i = 0; tests[i].cmd; i++) {
146 fprintf(stderr," %-8s %s\n", tests[i].cmd, tests[i].help);
191 for(i = 0; tests[i].cmd; i++) {
192 if(!strcmp(argv[1], tests[i].cmd)) {
193 usb = usb_open(tests[i].match);
194 if(tests[i].test) {
197 tests[i].cmd);
200 if(tests[i].test(usb)) {
201 fprintf(stderr,"usbtest: %s: FAIL\n", tests[i].cmd);
204 fprintf(stderr,"usbtest: %s: OKAY\n", tests[i].cmd);