Lines Matching defs:file
6 /*! Tests if the read functions of a file system work correctly by reading
7 arbitrary bytes at arbitrary positions of a file previously created.
10 of the file. It currently only counts numbers, beginning from zero,
42 BFile file;
43 status_t status = file.SetTo(name,
46 fprintf(stderr, "Could not create test file: %s!\n", strerror(status));
52 if (file.Write(&i, sizeof(test_t)) != sizeof(test_t)) {
53 fprintf(stderr,"Could not create the whole test file!\n");
63 BFile file;
64 status_t status = file.SetTo(name, B_READ_ONLY);
66 fprintf(stderr, "Could not open test file! Run \"randomread create "
68 "This will create a file named \"%s\" in the current directory.\n",
74 if ((status = file.GetSize(&size)) < B_OK) {
75 fprintf(stderr, "Could not get file size: %s!\n", strerror(status));
97 ssize_t bytesRead = file.ReadAt(pos, buffer, bytes);
203 printf("You can either create a test file or perform the test.\n"
214 fprintf(stderr, "%s: given file size too small, set to 1 MB.\n",