fix key lifetime set implementation , tests accordingly
diff --git a/tests/suites/test_suite_psa_crypto.function b/tests/suites/test_suite_psa_crypto.function
index 7cb38d9..c1bbe17 100644
--- a/tests/suites/test_suite_psa_crypto.function
+++ b/tests/suites/test_suite_psa_crypto.function
@@ -374,11 +374,11 @@
  
     TEST_ASSERT( psa_crypto_init( ) == PSA_SUCCESS );
 
-    TEST_ASSERT( psa_import_key( key_slot, key_type,
-                                 key, sizeof( key ) ) == PSA_SUCCESS );
-
     TEST_ASSERT( psa_set_key_lifetime( key_slot, 
                                  lifetime_set ) == PSA_SUCCESS );
+
+    TEST_ASSERT( psa_import_key( key_slot, key_type,
+                                 key, sizeof( key ) ) == PSA_SUCCESS );
     
     TEST_ASSERT( psa_get_key_lifetime( key_slot, 
                                  &lifetime_get ) == PSA_SUCCESS );
@@ -396,19 +396,12 @@
 void key_lifetime_set_fail( int key_slot_arg, int lifetime_arg, int expected_status_arg )
 {
     int key_slot = 1;
-    psa_key_type_t key_type = PSA_ALG_CBC_BASE;
-    unsigned char key[32] = {0};
     psa_key_lifetime_t lifetime_set = (psa_key_lifetime_t) lifetime_arg;
     psa_status_t actual_status;
     psa_status_t expected_status = expected_status_arg;
 
-    memset( key, 0x2a, sizeof( key ) );
- 
     TEST_ASSERT( psa_crypto_init( ) == PSA_SUCCESS );
 
-    TEST_ASSERT( psa_import_key( key_slot, key_type,
-                                 key, sizeof( key ) ) == PSA_SUCCESS );
-
     actual_status = psa_set_key_lifetime( key_slot_arg, lifetime_set );
 
     if( actual_status == PSA_SUCCESS )