2016-11-11 15:46:59 +01:00
|
|
|
const sinon = require('sinon');
|
|
|
|
|
|
|
|
const clientMetricsStore = require('./fake-metrics-store');
|
|
|
|
const clientStrategyStore = require('./fake-client-strategy-store');
|
|
|
|
const clientInstanceStore = require('./fake-client-instance-store');
|
|
|
|
const featureToggleStore = require('./fake-feature-toggle-store');
|
|
|
|
const strategyStore = require('./fake-strategies-store');
|
|
|
|
|
2016-11-11 16:24:16 +01:00
|
|
|
|
|
|
|
|
2016-11-11 15:46:59 +01:00
|
|
|
module.exports = {
|
|
|
|
createStores: () => {
|
2016-11-11 16:24:16 +01:00
|
|
|
const db = {
|
|
|
|
select: () => {
|
|
|
|
return {
|
|
|
|
from: () => Promise.resolve()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-11-11 15:46:59 +01:00
|
|
|
clientMetricsStore.reset();
|
|
|
|
clientStrategyStore.reset();
|
|
|
|
clientInstanceStore.reset();
|
|
|
|
featureToggleStore.reset();
|
|
|
|
strategyStore.reset();
|
|
|
|
|
|
|
|
return {
|
2016-11-11 16:24:16 +01:00
|
|
|
db,
|
2016-11-11 15:46:59 +01:00
|
|
|
clientMetricsStore,
|
|
|
|
clientStrategyStore,
|
|
|
|
clientInstanceStore,
|
|
|
|
featureToggleStore,
|
|
|
|
strategyStore,
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
};
|