##// END OF EJS Templates
Randomizes the time to wait between each operations (defines min/max delays)
Alexandre Leroux -
r1243:99981a2cca28
parent child
Show More
@@ -1,107 +1,107
1 1 #include "FuzzingDefs.h"
2 2
3 3 const QString NB_MAX_OPERATIONS_PROPERTY = QStringLiteral("component");
4 4 const QString NB_MAX_SYNC_GROUPS_PROPERTY = QStringLiteral("nbSyncGroups");
5 5 const QString NB_MAX_VARIABLES_PROPERTY = QStringLiteral("nbMaxVariables");
6 6 const QString AVAILABLE_OPERATIONS_PROPERTY = QStringLiteral("availableOperations");
7 7 const QString CACHE_TOLERANCE_PROPERTY = QStringLiteral("cacheTolerance");
8 8 const QString INITIAL_RANGE_PROPERTY = QStringLiteral("initialRange");
9 9 const QString MAX_RANGE_PROPERTY = QStringLiteral("maxRange");
10 10 const QString METADATA_POOL_PROPERTY = QStringLiteral("metadataPool");
11 11 const QString PROVIDER_PROPERTY = QStringLiteral("provider");
12 const QString OPERATION_DELAY_PROPERTY = QStringLiteral("operationDelay");
12 const QString OPERATION_DELAY_BOUNDS_PROPERTY = QStringLiteral("operationDelays");
13 13 const QString VALIDATORS_PROPERTY = QStringLiteral("validators");
14 14
15 15 // //////////// //
16 16 // FuzzingState //
17 17 // //////////// //
18 18
19 19 const SyncGroup &FuzzingState::syncGroup(SyncGroupId id) const
20 20 {
21 21 return m_SyncGroupsPool.at(id);
22 22 }
23 23
24 24 SyncGroup &FuzzingState::syncGroup(SyncGroupId id)
25 25 {
26 26 return m_SyncGroupsPool.at(id);
27 27 }
28 28
29 29 const VariableState &FuzzingState::variableState(VariableId id) const
30 30 {
31 31 return m_VariablesPool.at(id);
32 32 }
33 33
34 34 VariableState &FuzzingState::variableState(VariableId id)
35 35 {
36 36 return m_VariablesPool.at(id);
37 37 }
38 38
39 39 SyncGroupId FuzzingState::syncGroupId(VariableId variableId) const
40 40 {
41 41 auto end = m_SyncGroupsPool.cend();
42 42 auto it
43 43 = std::find_if(m_SyncGroupsPool.cbegin(), end, [&variableId](const auto &syncGroupEntry) {
44 44 const auto &syncGroup = syncGroupEntry.second;
45 45 return syncGroup.m_Variables.find(variableId) != syncGroup.m_Variables.end();
46 46 });
47 47
48 48 return it != end ? it->first : SyncGroupId{};
49 49 }
50 50
51 51 std::vector<SyncGroupId> FuzzingState::syncGroupsIds() const
52 52 {
53 53 std::vector<SyncGroupId> result{};
54 54
55 55 for (const auto &entry : m_SyncGroupsPool) {
56 56 result.push_back(entry.first);
57 57 }
58 58
59 59 return result;
60 60 }
61 61
62 62 void FuzzingState::synchronizeVariable(VariableId variableId, SyncGroupId syncGroupId)
63 63 {
64 64 if (syncGroupId.isNull()) {
65 65 return;
66 66 }
67 67
68 68 // Registers variable into sync group: if it's the first variable, sets the variable range as
69 69 // the sync group range
70 70 auto &syncGroup = m_SyncGroupsPool.at(syncGroupId);
71 71 syncGroup.m_Variables.insert(variableId);
72 72 if (syncGroup.m_Variables.size() == 1) {
73 73 auto &variableState = m_VariablesPool.at(variableId);
74 74 syncGroup.m_Range = variableState.m_Range;
75 75 }
76 76 }
77 77
78 78 void FuzzingState::desynchronizeVariable(VariableId variableId, SyncGroupId syncGroupId)
79 79 {
80 80 if (syncGroupId.isNull()) {
81 81 return;
82 82 }
83 83
84 84 // Unregisters variable from sync group: if there is no more variable in the group, resets the
85 85 // range
86 86 auto &syncGroup = m_SyncGroupsPool.at(syncGroupId);
87 87 syncGroup.m_Variables.erase(variableId);
88 88 if (syncGroup.m_Variables.empty()) {
89 89 syncGroup.m_Range = INVALID_RANGE;
90 90 }
91 91 }
92 92
93 93 void FuzzingState::updateRanges(VariableId variableId, const SqpRange &newRange)
94 94 {
95 95 auto syncGroupId = this->syncGroupId(variableId);
96 96
97 97 // Retrieves the variables to update:
98 98 // - if the variable is synchronized to others, updates all synchronized variables
99 99 // - otherwise, updates only the variable
100 100 auto variablesToUpdate = syncGroupId.isNull() ? std::set<VariableId>{variableId}
101 101 : m_SyncGroupsPool.at(syncGroupId).m_Variables;
102 102
103 103 // Sets new range
104 104 for (const auto &variableId : variablesToUpdate) {
105 105 m_VariablesPool.at(variableId).m_Range = newRange;
106 106 }
107 107 }
@@ -1,122 +1,122
1 1 #ifndef SCIQLOP_FUZZINGDEFS_H
2 2 #define SCIQLOP_FUZZINGDEFS_H
3 3
4 4 #include <Data/SqpRange.h>
5 5
6 6 #include <QString>
7 7 #include <QUuid>
8 8 #include <QVariantHash>
9 9
10 10 #include <memory>
11 11 #include <set>
12 12
13 13 // /////// //
14 14 // Aliases //
15 15 // /////// //
16 16
17 17 using MetadataPool = std::vector<QVariantHash>;
18 18 Q_DECLARE_METATYPE(MetadataPool)
19 19
20 20 using Properties = QVariantHash;
21 21
22 22 // ///////// //
23 23 // Constants //
24 24 // ///////// //
25 25
26 26 /// Max number of operations to generate
27 27 extern const QString NB_MAX_OPERATIONS_PROPERTY;
28 28
29 29 /// Max number of sync groups to create through operations
30 30 extern const QString NB_MAX_SYNC_GROUPS_PROPERTY;
31 31
32 32 /// Max number of variables to manipulate through operations
33 33 extern const QString NB_MAX_VARIABLES_PROPERTY;
34 34
35 35 /// Set of operations available for the test
36 36 extern const QString AVAILABLE_OPERATIONS_PROPERTY;
37 37
38 38 /// Tolerance used for variable's cache (in ratio)
39 39 extern const QString CACHE_TOLERANCE_PROPERTY;
40 40
41 41 /// Range with which the timecontroller is initialized
42 42 extern const QString INITIAL_RANGE_PROPERTY;
43 43
44 44 /// Max range that an operation can reach
45 45 extern const QString MAX_RANGE_PROPERTY;
46 46
47 47 /// Set of metadata that can be associated to a variable
48 48 extern const QString METADATA_POOL_PROPERTY;
49 49
50 50 /// Provider used to retrieve data
51 51 extern const QString PROVIDER_PROPERTY;
52 52
53 /// Time left for an operation to execute
54 extern const QString OPERATION_DELAY_PROPERTY;
53 /// Min/max times left for an operation to execute
54 extern const QString OPERATION_DELAY_BOUNDS_PROPERTY;
55 55
56 56 /// Validators used to validate an operation
57 57 extern const QString VALIDATORS_PROPERTY;
58 58
59 59 // /////// //
60 60 // Structs //
61 61 // /////// //
62 62
63 63 class Variable;
64 64 struct VariableState {
65 65 std::shared_ptr<Variable> m_Variable{nullptr};
66 66 SqpRange m_Range{INVALID_RANGE};
67 67 };
68 68
69 69 using VariableId = int;
70 70 using VariablesPool = std::map<VariableId, VariableState>;
71 71
72 72 /**
73 73 * Defines a synchronization group for a fuzzing state. A group reports the variables synchronized
74 74 * with each other, and the current range of the group (i.e. range of the last synchronized variable
75 75 * that has been moved)
76 76 */
77 77 struct SyncGroup {
78 78 std::set<VariableId> m_Variables{};
79 79 SqpRange m_Range{INVALID_RANGE};
80 80 };
81 81
82 82 using SyncGroupId = QUuid;
83 83 using SyncGroupsPool = std::map<SyncGroupId, SyncGroup>;
84 84
85 85 /**
86 86 * Defines a current state during a fuzzing state. It contains all the variables manipulated during
87 87 * the test, as well as the synchronization status of these variables.
88 88 */
89 89 struct FuzzingState {
90 90 const SyncGroup &syncGroup(SyncGroupId id) const;
91 91 SyncGroup &syncGroup(SyncGroupId id);
92 92
93 93 const VariableState &variableState(VariableId id) const;
94 94 VariableState &variableState(VariableId id);
95 95
96 96 /// @return the identifier of the synchronization group in which the variable passed in
97 97 /// parameter is located. If the variable is not in any group, returns an invalid identifier
98 98 SyncGroupId syncGroupId(VariableId variableId) const;
99 99
100 100 /// @return the set of synchronization group identifiers
101 101 std::vector<SyncGroupId> syncGroupsIds() const;
102 102
103 103 /// Updates fuzzing state according to a variable synchronization
104 104 /// @param variableId the variable that is synchronized
105 105 /// @param syncGroupId the synchronization group
106 106 void synchronizeVariable(VariableId variableId, SyncGroupId syncGroupId);
107 107
108 108 /// Updates fuzzing state according to a variable desynchronization
109 109 /// @param variableId the variable that is desynchronized
110 110 /// @param syncGroupId the synchronization group from which to remove the variable
111 111 void desynchronizeVariable(VariableId variableId, SyncGroupId syncGroupId);
112 112
113 113 /// Updates the range of a variable and all variables to which it is synchronized
114 114 /// @param the variable for which to affect the range
115 115 /// @param the range to affect
116 116 void updateRanges(VariableId variableId, const SqpRange &newRange);
117 117
118 118 VariablesPool m_VariablesPool;
119 119 SyncGroupsPool m_SyncGroupsPool;
120 120 };
121 121
122 122 #endif // SCIQLOP_FUZZINGDEFS_H
@@ -1,346 +1,354
1 1 #include "FuzzingDefs.h"
2 2 #include "FuzzingOperations.h"
3 3 #include "FuzzingUtils.h"
4 4 #include "FuzzingValidators.h"
5 5
6 6 #include "AmdaProvider.h"
7 7
8 8 #include <Network/NetworkController.h>
9 9 #include <Settings/SqpSettingsDefs.h>
10 10 #include <SqpApplication.h>
11 11 #include <Time/TimeController.h>
12 12 #include <Variable/Variable.h>
13 13 #include <Variable/VariableController.h>
14 14
15 15 #include <QLoggingCategory>
16 16 #include <QObject>
17 17 #include <QtTest>
18 18
19 19 #include <memory>
20 20
21 21 Q_LOGGING_CATEGORY(LOG_TestAmdaFuzzing, "TestAmdaFuzzing")
22 22
23 23 namespace {
24 24
25 25 // /////// //
26 26 // Aliases //
27 27 // /////// //
28 28
29 29 using Weight = double;
30 30 using Weights = std::vector<Weight>;
31 31
32 32 using VariableOperation = std::pair<VariableId, std::shared_ptr<IFuzzingOperation> >;
33 33 using VariablesOperations = std::vector<VariableOperation>;
34 34
35 35 using WeightedOperationsPool = std::map<std::shared_ptr<IFuzzingOperation>, Weight>;
36 36 using Validators = std::vector<std::shared_ptr<IFuzzingValidator> >;
37 37
38 38 // ///////// //
39 39 // Constants //
40 40 // ///////// //
41 41
42 42 // Defaults values used when the associated properties have not been set for the test
43 43 const auto NB_MAX_OPERATIONS_DEFAULT_VALUE = 100;
44 44 const auto NB_MAX_SYNC_GROUPS_DEFAULT_VALUE = 1;
45 45 const auto NB_MAX_VARIABLES_DEFAULT_VALUE = 1;
46 46 const auto AVAILABLE_OPERATIONS_DEFAULT_VALUE = QVariant::fromValue(WeightedOperationsTypes{
47 47 {FuzzingOperationType::CREATE, 1.},
48 48 {FuzzingOperationType::DELETE, 0.1}, // Delete operation is less frequent
49 49 {FuzzingOperationType::PAN_LEFT, 1.},
50 50 {FuzzingOperationType::PAN_RIGHT, 1.},
51 51 {FuzzingOperationType::ZOOM_IN, 1.},
52 52 {FuzzingOperationType::ZOOM_OUT, 1.},
53 53 {FuzzingOperationType::SYNCHRONIZE, 0.8},
54 54 {FuzzingOperationType::DESYNCHRONIZE, 0.4}});
55 55 const auto CACHE_TOLERANCE_DEFAULT_VALUE = 0.2;
56 56
57 /// Delay between each operation (in ms)
58 const auto OPERATION_DELAY_DEFAULT_VALUE = 3000;
57 /// Min/max delays between each operation (in ms)
58 const auto OPERATION_DELAY_BOUNDS_DEFAULT_VALUE = QVariant::fromValue(std::make_pair(100, 3000));
59 59
60 60 /// Validators for the tests (executed in the order in which they're defined)
61 61 const auto VALIDATORS_DEFAULT_VALUE = QVariant::fromValue(
62 62 ValidatorsTypes{{FuzzingValidatorType::RANGE, FuzzingValidatorType::DATA}});
63 63
64 64 // /////// //
65 65 // Methods //
66 66 // /////// //
67 67
68 68 /// Goes through the variables pool and operations pool to determine the set of {variable/operation}
69 69 /// pairs that are valid (i.e. operation that can be executed on variable)
70 70 std::pair<VariablesOperations, Weights>
71 71 availableOperations(const FuzzingState &fuzzingState, const WeightedOperationsPool &operationsPool)
72 72 {
73 73 VariablesOperations result{};
74 74 Weights weights{};
75 75
76 76 for (const auto &variablesPoolEntry : fuzzingState.m_VariablesPool) {
77 77 auto variableId = variablesPoolEntry.first;
78 78
79 79 for (const auto &operationsPoolEntry : operationsPool) {
80 80 auto operation = operationsPoolEntry.first;
81 81 auto weight = operationsPoolEntry.second;
82 82
83 83 // A pair is valid if the current operation can be executed on the current variable
84 84 if (operation->canExecute(variableId, fuzzingState)) {
85 85 result.push_back({variableId, operation});
86 86 weights.push_back(weight);
87 87 }
88 88 }
89 89 }
90 90
91 91 return {result, weights};
92 92 }
93 93
94 94 WeightedOperationsPool createOperationsPool(const WeightedOperationsTypes &types)
95 95 {
96 96 WeightedOperationsPool result{};
97 97
98 98 std::transform(
99 99 types.cbegin(), types.cend(), std::inserter(result, result.end()), [](const auto &type) {
100 100 return std::make_pair(FuzzingOperationFactory::create(type.first), type.second);
101 101 });
102 102
103 103 return result;
104 104 }
105 105
106 106 Validators createValidators(const ValidatorsTypes &types)
107 107 {
108 108 Validators result{};
109 109
110 110 std::transform(types.cbegin(), types.cend(), std::inserter(result, result.end()),
111 111 [](const auto &type) { return FuzzingValidatorFactory::create(type); });
112 112
113 113 return result;
114 114 }
115 115
116 116 /**
117 117 * Validates all the variables' states passed in parameter, according to a set of validators
118 118 * @param variablesPool the variables' states
119 119 * @param validators the validators used for validation
120 120 */
121 121 void validate(const VariablesPool &variablesPool, const Validators &validators)
122 122 {
123 123 for (const auto &variablesPoolEntry : variablesPool) {
124 124 auto variableId = variablesPoolEntry.first;
125 125 const auto &variableState = variablesPoolEntry.second;
126 126
127 127 auto variableMessage = variableState.m_Variable ? variableState.m_Variable->name()
128 128 : QStringLiteral("null variable");
129 129 qCInfo(LOG_TestAmdaFuzzing()).noquote() << "Validating state of variable at index"
130 130 << variableId << "(" << variableMessage << ")...";
131 131
132 132 for (const auto &validator : validators) {
133 133 validator->validate(VariableState{variableState});
134 134 }
135 135
136 136 qCInfo(LOG_TestAmdaFuzzing()).noquote() << "Validation completed.";
137 137 }
138 138 }
139 139
140 140 /**
141 141 * Class to run random tests
142 142 */
143 143 class FuzzingTest {
144 144 public:
145 145 explicit FuzzingTest(VariableController &variableController, Properties properties)
146 146 : m_VariableController{variableController},
147 147 m_Properties{std::move(properties)},
148 148 m_FuzzingState{}
149 149 {
150 150 // Inits variables pool: at init, all variables are null
151 151 for (auto variableId = 0; variableId < nbMaxVariables(); ++variableId) {
152 152 m_FuzzingState.m_VariablesPool[variableId] = VariableState{};
153 153 }
154 154
155 155 // Inits sync groups and registers them into the variable controller
156 156 for (auto i = 0; i < nbMaxSyncGroups(); ++i) {
157 157 auto syncGroupId = SyncGroupId::createUuid();
158 158 variableController.onAddSynchronizationGroupId(syncGroupId);
159 159 m_FuzzingState.m_SyncGroupsPool[syncGroupId] = SyncGroup{};
160 160 }
161 161 }
162 162
163 163 void execute()
164 164 {
165 165 qCInfo(LOG_TestAmdaFuzzing()).noquote() << "Running" << nbMaxOperations() << "operations on"
166 166 << nbMaxVariables() << "variable(s)...";
167 167
168 168 auto canExecute = true;
169 169 for (auto i = 0; i < nbMaxOperations() && canExecute; ++i) {
170 170 // Retrieves all operations that can be executed in the current context
171 171 VariablesOperations variableOperations{};
172 172 Weights weights{};
173 173 std::tie(variableOperations, weights)
174 174 = availableOperations(m_FuzzingState, operationsPool());
175 175
176 176 canExecute = !variableOperations.empty();
177 177 if (canExecute) {
178 178 // Of the operations available, chooses a random operation and executes it
179 179 auto variableOperation
180 180 = RandomGenerator::instance().randomChoice(variableOperations, weights);
181 181
182 182 auto variableId = variableOperation.first;
183 183 auto fuzzingOperation = variableOperation.second;
184 184
185 185 fuzzingOperation->execute(variableId, m_FuzzingState, m_VariableController,
186 186 m_Properties);
187 QTest::qWait(operationDelay());
187
188 // Delays the next operation with a randomly generated time
189 auto delay = RandomGenerator::instance().generateInt(operationDelays().first,
190 operationDelays().second);
191 qCDebug(LOG_TestAmdaFuzzing())
192 << "Waiting " << delay << "ms before the next operation...";
193 QTest::qWait(delay);
188 194
189 195 // Validates variables
190 196 validate(m_FuzzingState.m_VariablesPool, validators());
191 197 }
192 198 else {
193 199 qCInfo(LOG_TestAmdaFuzzing()).noquote()
194 200 << "No more operations are available, the execution of the test will stop...";
195 201 }
196 202 }
197 203
198 204 qCInfo(LOG_TestAmdaFuzzing()).noquote() << "Execution of the test completed.";
199 205 }
200 206
201 207 private:
202 208 int nbMaxOperations() const
203 209 {
204 210 static auto result
205 211 = m_Properties.value(NB_MAX_OPERATIONS_PROPERTY, NB_MAX_OPERATIONS_DEFAULT_VALUE)
206 212 .toInt();
207 213 return result;
208 214 }
209 215
210 216 int nbMaxSyncGroups() const
211 217 {
212 218 static auto result
213 219 = m_Properties.value(NB_MAX_SYNC_GROUPS_PROPERTY, NB_MAX_SYNC_GROUPS_DEFAULT_VALUE)
214 220 .toInt();
215 221 return result;
216 222 }
217 223
218 224 int nbMaxVariables() const
219 225 {
220 226 static auto result
221 227 = m_Properties.value(NB_MAX_VARIABLES_PROPERTY, NB_MAX_VARIABLES_DEFAULT_VALUE).toInt();
222 228 return result;
223 229 }
224 230
225 int operationDelay() const
231 std::pair<int, int> operationDelays() const
226 232 {
227 233 static auto result
228 = m_Properties.value(OPERATION_DELAY_PROPERTY, OPERATION_DELAY_DEFAULT_VALUE).toInt();
234 = m_Properties
235 .value(OPERATION_DELAY_BOUNDS_PROPERTY, OPERATION_DELAY_BOUNDS_DEFAULT_VALUE)
236 .value<std::pair<int, int> >();
229 237 return result;
230 238 }
231 239
232 240 WeightedOperationsPool operationsPool() const
233 241 {
234 242 static auto result = createOperationsPool(
235 243 m_Properties.value(AVAILABLE_OPERATIONS_PROPERTY, AVAILABLE_OPERATIONS_DEFAULT_VALUE)
236 244 .value<WeightedOperationsTypes>());
237 245 return result;
238 246 }
239 247
240 248 Validators validators() const
241 249 {
242 250 static auto result
243 251 = createValidators(m_Properties.value(VALIDATORS_PROPERTY, VALIDATORS_DEFAULT_VALUE)
244 252 .value<ValidatorsTypes>());
245 253 return result;
246 254 }
247 255
248 256 VariableController &m_VariableController;
249 257 Properties m_Properties;
250 258 FuzzingState m_FuzzingState;
251 259 };
252 260
253 261 } // namespace
254 262
255 263 class TestAmdaFuzzing : public QObject {
256 264 Q_OBJECT
257 265
258 266 private slots:
259 267 /// Input data for @sa testFuzzing()
260 268 void testFuzzing_data();
261 269 void testFuzzing();
262 270 };
263 271
264 272 void TestAmdaFuzzing::testFuzzing_data()
265 273 {
266 274 // ////////////// //
267 275 // Test structure //
268 276 // ////////////// //
269 277
270 278 QTest::addColumn<Properties>("properties"); // Properties for random test
271 279
272 280 // ////////// //
273 281 // Test cases //
274 282 // ////////// //
275 283
276 284 auto maxRange = SqpRange::fromDateTime({2017, 1, 1}, {0, 0}, {2017, 1, 5}, {0, 0});
277 285 MetadataPool metadataPool{{{"dataType", "vector"}, {"xml:id", "imf"}}};
278 286
279 287 // Note: we don't use auto here as we want to pass std::shared_ptr<IDataProvider> as is in the
280 288 // QVariant
281 289 std::shared_ptr<IDataProvider> provider = std::make_shared<AmdaProvider>();
282 290
283 291 QTest::newRow("fuzzingTest") << Properties{
284 292 {MAX_RANGE_PROPERTY, QVariant::fromValue(maxRange)},
285 293 {METADATA_POOL_PROPERTY, QVariant::fromValue(metadataPool)},
286 294 {PROVIDER_PROPERTY, QVariant::fromValue(provider)}};
287 295 }
288 296
289 297 void TestAmdaFuzzing::testFuzzing()
290 298 {
291 299 QFETCH(Properties, properties);
292 300
293 301 // Sets cache property
294 302 QSettings settings{};
295 303 auto cacheTolerance = properties.value(CACHE_TOLERANCE_PROPERTY, CACHE_TOLERANCE_DEFAULT_VALUE);
296 304 settings.setValue(GENERAL_TOLERANCE_AT_INIT_KEY, cacheTolerance);
297 305 settings.setValue(GENERAL_TOLERANCE_AT_UPDATE_KEY, cacheTolerance);
298 306
299 307 auto &variableController = sqpApp->variableController();
300 308 auto &timeController = sqpApp->timeController();
301 309
302 310 // Generates random initial range (bounded to max range)
303 311 auto maxRange = properties.value(MAX_RANGE_PROPERTY, QVariant::fromValue(INVALID_RANGE))
304 312 .value<SqpRange>();
305 313
306 314 QVERIFY(maxRange != INVALID_RANGE);
307 315
308 316 auto initialRangeStart
309 317 = RandomGenerator::instance().generateDouble(maxRange.m_TStart, maxRange.m_TEnd);
310 318 auto initialRangeEnd
311 319 = RandomGenerator::instance().generateDouble(maxRange.m_TStart, maxRange.m_TEnd);
312 320 if (initialRangeStart > initialRangeEnd) {
313 321 std::swap(initialRangeStart, initialRangeEnd);
314 322 }
315 323
316 324 // Sets initial range on time controller
317 325 SqpRange initialRange{initialRangeStart, initialRangeEnd};
318 326 qCInfo(LOG_TestAmdaFuzzing()).noquote() << "Setting initial range to" << initialRange << "...";
319 327 timeController.onTimeToUpdate(initialRange);
320 328 properties.insert(INITIAL_RANGE_PROPERTY, QVariant::fromValue(initialRange));
321 329
322 330 FuzzingTest test{variableController, properties};
323 331 test.execute();
324 332 }
325 333
326 334 int main(int argc, char *argv[])
327 335 {
328 336 QLoggingCategory::setFilterRules(
329 337 "*.warning=false\n"
330 338 "*.info=false\n"
331 339 "*.debug=false\n"
332 340 "FuzzingOperations.info=true\n"
333 341 "FuzzingValidators.info=true\n"
334 342 "TestAmdaFuzzing.info=true\n");
335 343
336 344 SqpApplication app{argc, argv};
337 345 SqpApplication::setOrganizationName("LPP");
338 346 SqpApplication::setOrganizationDomain("lpp.fr");
339 347 SqpApplication::setApplicationName("SciQLop-TestFuzzing");
340 348 app.setAttribute(Qt::AA_Use96Dpi, true);
341 349 TestAmdaFuzzing testObject{};
342 350 QTEST_SET_MAIN_SOURCE_PATH
343 351 return QTest::qExec(&testObject, argc, argv);
344 352 }
345 353
346 354 #include "TestAmdaFuzzing.moc"
General Comments 0
You need to be logged in to leave comments. Login now