Commit f1d5b947 authored by Milan Broz's avatar Milan Broz

Run API tests without verbose flag by default.

And rename some tests.
parent 6fc2e7c7
......@@ -354,7 +354,7 @@ static int _setup(void)
fd = loop_attach(&DEVICE_6, IMAGE_PV_LUKS2_SEC, 0, 0, &ro);
close(fd);
_system(" [ ! -d " CONV_DIR " ] && tar xJf " CONV_DIR ".tar.xz", 1);
_system(" [ ! -d " CONV_DIR " ] && tar xJf " CONV_DIR ".tar.xz 2>/dev/null", 1);
if (_system("modprobe dm-crypt", 1))
return 1;
......@@ -2974,23 +2974,23 @@ int main(int argc, char *argv[])
crypt_set_debug_level(_debug ? CRYPT_DEBUG_ALL : CRYPT_DEBUG_NONE);
RUN_(AddDeviceLuks2, "Format and use LUKS2 device");
RUN_(Luks2HeaderLoad, "test header load");
RUN_(Luks2HeaderRestore, "test LUKS2 header restore");
RUN_(Luks2HeaderBackup, "test LUKS2 header backup");
RUN_(ResizeDeviceLuks2, "Luks device resize tests");
RUN_(Luks2HeaderLoad, "LUKS2 header load");
RUN_(Luks2HeaderRestore, "LUKS2 header restore");
RUN_(Luks2HeaderBackup, "LUKS2 header backup");
RUN_(ResizeDeviceLuks2, "LUKS2 device resize tests");
RUN_(UseLuks2Device, "Use pre-formated LUKS2 device");
RUN_(SuspendDevice, "Suspend/Resume test");
RUN_(SuspendDevice, "LUKS2 Suspend/Resume");
RUN_(UseTempVolumes, "Format and use temporary encrypted device");
RUN_(Tokens, "General tokens API tests");
RUN_(TokenActivationByKeyring, "Builtin kernel keyring token tests");
RUN_(LuksConvert, "Test LUKS1 <-> LUKS2 conversions");
RUN_(Pbkdf, "Exercice default pbkdf manipulation routines");
RUN_(Luks2KeyslotAdd, "Add new keyslot by unused key");
RUN_(Luks2ActivateByKeyring, "Test LUKS2 activation by passphrase in keyring");
RUN_(Luks2Requirements, "Test LUKS2 requirements flags");
RUN_(Luks2Integrity, "Test LUKS2 with data integrity");
RUN_(Luks2Flags, "Test LUKS2 persistent flags");
RUN_(Luks2Repair, "Test LUKS2 repair"); // test disables metadata locking. Run alwas last!
RUN_(Tokens, "General tokens API");
RUN_(TokenActivationByKeyring, "Builtin kernel keyring token");
RUN_(LuksConvert, "LUKS1 <-> LUKS2 conversions");
RUN_(Pbkdf, "Default PBKDF manipulation routines");
RUN_(Luks2KeyslotAdd, "Add a new keyslot by unused key");
RUN_(Luks2ActivateByKeyring, "LUKS2 activation by passphrase in keyring");
RUN_(Luks2Requirements, "LUKS2 requirements flags");
RUN_(Luks2Integrity, "LUKS2 with data integrity");
RUN_(Luks2Flags, "LUKS2 persistent flags");
RUN_(Luks2Repair, "LUKS2 repair"); // test disables metadata locking. Run always last!
out:
_cleanup();
return 0;
......
......@@ -104,7 +104,6 @@ static int get_luks_offsets(int metadata_device,
return -1;
sectors_per_stripes_set = DIV_ROUND_UP(keylength*LUKS_STRIPES, SECTOR_SIZE);
printf("sectors_per_stripes %" PRIu32 "\n", sectors_per_stripes_set);
current_sector = DIV_ROUND_UP_MODULO(DIV_ROUND_UP(LUKS_PHDR_SIZE_B, SECTOR_SIZE),
LUKS_ALIGN_KEYSLOTS / SECTOR_SIZE);
for(i=0;i < (LUKS_NUMKEYS - 1);i++)
......@@ -1762,20 +1761,20 @@ int main(int argc, char *argv[])
crypt_set_debug_level(_debug ? CRYPT_DEBUG_ALL : CRYPT_DEBUG_NONE);
RUN_(NonFIPSAlg, "Crypto is properly initialised in format"); //must be the first!
RUN_(AddDevicePlain, "plain device API creation exercise");
RUN_(HashDevicePlain, "plain device API hash test");
RUN_(AddDevicePlain, "A plain device API creation");
RUN_(HashDevicePlain, "A plain device API hash");
RUN_(AddDeviceLuks, "Format and use LUKS device");
RUN_(LuksHeaderLoad, "test header load");
RUN_(LuksHeaderRestore, "test LUKS header restore");
RUN_(LuksHeaderBackup, "test LUKS header backup");
RUN_(ResizeDeviceLuks, "Luks device resize tests");
RUN_(LuksHeaderLoad, "Header load");
RUN_(LuksHeaderRestore, "LUKS header restore");
RUN_(LuksHeaderBackup, "LUKS header backup");
RUN_(ResizeDeviceLuks, "LUKS device resize");
RUN_(UseLuksDevice, "Use pre-formated LUKS device");
RUN_(SuspendDevice, "Suspend/Resume test");
RUN_(SuspendDevice, "Suspend/Resume");
RUN_(UseTempVolumes, "Format and use temporary encrypted device");
RUN_(CallbacksTest, "API callbacks test");
RUN_(VerityTest, "DM verity test");
RUN_(TcryptTest, "Tcrypt API test");
RUN_(IntegrityTest, "Integrity API test");
RUN_(CallbacksTest, "API callbacks");
RUN_(VerityTest, "DM verity");
RUN_(TcryptTest, "Tcrypt API");
RUN_(IntegrityTest, "Integrity API");
out:
_cleanup();
return 0;
......
......@@ -45,7 +45,7 @@ char *THE_LOOP_DEV = NULL;
int _debug = 0;
int global_lines = 0;
int _quit = 0;
int _verbose = 1;
int _verbose = 0;
uint64_t t_dev_offset = 0;
static void (*_cleanup)(void);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment