In this patch is testing the crypt(TEA) class of QQ Protocol which encipher and decipher the text.
Details
Diff Detail
- Lint
Lint Skipped - Unit
Unit Tests Skipped
tests/protocols/qq/qqcrypttest.cpp | ||
---|---|---|
12 | Make this test data-driven. |
Hi,
I have some difficulties in making this test into the data-driven test.
For the data-driven, I have the problem in defining the array type the data
function. how to use this function to store the array type values
QTest::addColumn<int>("result");
here in the example defining the Int
data type
but
I
want to use
its
n *array* instead of
*int.*
I try Q_DECLARE_METATYPE() to define it like this
/**********
namespace CryptData
{
struct Data { unsigned int a[2]; }; struct Key { unsigned int k[4]; };
}
Q_DECLARE_METATYPE(CryptData::Data)
Q_DECLARE_METATYPE(CryptData::Key)
/***********
but in this method I face lot of troubles in initializing the value by
function newRow().
Can I test with more values instead of data-driven?
I don't know what should I do.
please help!!