@capillarytech/creatives-library 8.0.52-alpha.0 → 8.0.53-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -41,7 +41,7 @@ import injectReducer from '../../utils/injectReducer';
|
|
|
41
41
|
import injectSaga from '../../utils/injectSaga';
|
|
42
42
|
import reducer from './reducer';
|
|
43
43
|
import zaloReducer from '../Zalo/reducer';
|
|
44
|
-
import { v2CapSagas } from './sagas';
|
|
44
|
+
import { capSagaLiquidEntity, v2CapSagas } from './sagas';
|
|
45
45
|
import { v2SmsCreateSagas } from '../Sms/Create/sagas';
|
|
46
46
|
import { v2EbillSagas } from '../Ebill/sagas';
|
|
47
47
|
import { v2EmailDuplicateTemplateSaga } from '../Email/sagas';
|
|
@@ -54,6 +54,7 @@ import { v2ViberSagas } from '../Viber/sagas';
|
|
|
54
54
|
import { v2FacebookSagas } from '../Facebook/sagas';
|
|
55
55
|
import createReducer from '../Line/Container/reducer';
|
|
56
56
|
import { v2ZaloSagas } from '../Zalo/saga';
|
|
57
|
+
import { DAEMON } from '@capillarytech/vulcan-react-sdk/utils/sagaInjectorTypes';
|
|
57
58
|
|
|
58
59
|
const gtm = window.dataLayer || [];
|
|
59
60
|
const {
|
|
@@ -611,6 +612,7 @@ const withConnect = connect(mapStateToProps, mapDispatchToProps);
|
|
|
611
612
|
const withReducer = injectReducer({ key: 'cap', reducer });
|
|
612
613
|
const withZaloReducer = injectReducer({ key: 'zalo', reducer: zaloReducer });
|
|
613
614
|
const withSaga = injectSaga({ key: 'cap', saga: v2CapSagas });
|
|
615
|
+
const withLiquidSaga = injectSaga({ key: 'liquid', saga: capSagaLiquidEntity, mode : DAEMON });
|
|
614
616
|
const withSmsCreateSaga = injectSaga({ key: 'create', saga: v2SmsCreateSagas });
|
|
615
617
|
const withEbillSaga = injectSaga({ key: 'ebill', saga: v2EbillSagas });
|
|
616
618
|
const withEmailSaga = injectSaga({ key: 'email', saga: v2EmailDuplicateTemplateSaga });
|
|
@@ -629,6 +631,7 @@ export default compose(
|
|
|
629
631
|
withSmsCreateSaga,
|
|
630
632
|
withEbillSaga,
|
|
631
633
|
withEmailSaga,
|
|
634
|
+
withLiquidSaga,
|
|
632
635
|
withLineContainerSaga,
|
|
633
636
|
withMobilePushCreateSaga,
|
|
634
637
|
withWechatMapTemplatesSaga,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { take, fork, cancel, takeLatest } from 'redux-saga/effects';
|
|
2
2
|
import { expectSaga } from 'redux-saga-test-plan';
|
|
3
3
|
import * as matchers from 'redux-saga-test-plan/matchers';
|
|
4
|
-
import { authorize, loginFlow, fetchSchemaForEntity,v2CapSagas, getSupportVideosConfig, watchForGetVideosConfig, watchFetchSchemaForEntity,watchLiquidEntity, getLiquidTags, logoutFlow } from '../sagas';
|
|
4
|
+
import { authorize, loginFlow, fetchSchemaForEntity,v2CapSagas, getSupportVideosConfig, watchForGetVideosConfig, watchFetchSchemaForEntity,watchLiquidEntity, getLiquidTags, logoutFlow, capSagaLiquidEntity } from '../sagas';
|
|
5
5
|
import { throwError } from 'redux-saga-test-plan/providers';
|
|
6
6
|
import * as api from '../../../services/api';
|
|
7
7
|
import {
|
|
@@ -28,6 +28,13 @@ describe('v2CapSagas', () => {
|
|
|
28
28
|
return expectSaga(v2CapSagas).run();
|
|
29
29
|
});
|
|
30
30
|
});
|
|
31
|
+
|
|
32
|
+
describe('capSagaLiquidEntity', () => {
|
|
33
|
+
it("should initialize all capSagaLiquidEntity-related watcher sagas without error", () => {
|
|
34
|
+
return expectSaga(capSagaLiquidEntity).run();
|
|
35
|
+
});
|
|
36
|
+
});
|
|
37
|
+
|
|
31
38
|
describe('logoutFlow [Unit Test]', () => {
|
|
32
39
|
describe('logoutFlow saga', () => {
|
|
33
40
|
it('handle valid response from api', async () => {
|
|
@@ -56,6 +56,7 @@ import { v2TemplateSagaWatchGetDefaultBeeTemplates } from '../Templates/sagas';
|
|
|
56
56
|
import {
|
|
57
57
|
CAP_SPACE_32, CAP_SPACE_56, CAP_SPACE_64,
|
|
58
58
|
} from '@capillarytech/cap-ui-library/styled/variables';
|
|
59
|
+
import { DAEMON } from '@capillarytech/vulcan-react-sdk/utils/sagaInjectorTypes';
|
|
59
60
|
|
|
60
61
|
const classPrefix = 'add-creatives-section';
|
|
61
62
|
const CREATIVES_CONTAINER = 'creativesContainer';
|
|
@@ -1447,7 +1448,7 @@ function mapDispatchToProps(dispatch) {
|
|
|
1447
1448
|
const withConnect = connect(mapStatesToProps, mapDispatchToProps);
|
|
1448
1449
|
const withReducer = injectReducer({ key: 'creativesContainer', reducer: creativesContainerReducer });
|
|
1449
1450
|
const withSaga = injectSaga({ key: 'cap', saga: capSagaForFetchSchemaForEntity });
|
|
1450
|
-
const withLiquidSaga = injectSaga({ key: 'liquid', saga: capSagaLiquidEntity });
|
|
1451
|
+
const withLiquidSaga = injectSaga({ key: 'liquid', saga: capSagaLiquidEntity , mode: DAEMON });
|
|
1451
1452
|
const withDefaultTempSaga = injectSaga({ key: 'creativesContainer', saga: v2TemplateSagaWatchGetDefaultBeeTemplates });
|
|
1452
1453
|
|
|
1453
1454
|
export default compose(withSaga,withLiquidSaga, withDefaultTempSaga, withReducer, withConnect)(injectIntl(Creatives));
|