@@ -2,7 +2,7 @@ import Store, { IStore } from '../../src/store';
22import { IMParticleWebSDKInstance } from '../../src/mp-instance' ;
33import { SDKInitConfig } from '../../src/sdkRuntimeModels' ;
44
5- describe ( 'Persistence writers ' , ( ) => {
5+ describe ( 'Persistence store ' , ( ) => {
66 let store : IStore ;
77 let mockMPInstance : IMParticleWebSDKInstance ;
88
@@ -49,14 +49,14 @@ describe('Persistence writers', () => {
4949 Store . call ( store , { } as SDKInitConfig , mockMPInstance , 'apikey' ) ;
5050 } ) ;
5151
52- describe ( '#noFunctional' , ( ) => {
52+ describe ( '#noFunctional privacy flag ' , ( ) => {
5353 describe ( 'true' , ( ) => {
5454 beforeEach ( ( ) => {
5555 store . setNoFunctional ( true ) ;
5656 store . webviewBridgeEnabled = false ;
5757 } ) ;
5858
59- it ( 'should NOT write to cookie when useCookieStorage = true' , ( ) => {
59+ it ( 'should NOT write to cookie when useCookieStorage is true' , ( ) => {
6060 store . SDKConfig . useCookieStorage = true ;
6161 jest . clearAllMocks ( ) ;
6262
@@ -67,7 +67,7 @@ describe('Persistence writers', () => {
6767 expect ( mockMPInstance . _Persistence . setProductStorage ) . toHaveBeenCalled ( ) ;
6868 } ) ;
6969
70- it ( 'should NOT write to localStorage when useCookieStorage = false' , ( ) => {
70+ it ( 'should NOT write to localStorage when useCookieStorage is false' , ( ) => {
7171 store . SDKConfig . useCookieStorage = false ;
7272 jest . clearAllMocks ( ) ;
7373
@@ -85,7 +85,7 @@ describe('Persistence writers', () => {
8585 store . webviewBridgeEnabled = false ;
8686 } ) ;
8787
88- it ( 'should write to cookie when useCookieStorage = true' , ( ) => {
88+ it ( 'should write to cookie when useCookieStorage is true' , ( ) => {
8989 store . SDKConfig . useCookieStorage = true ;
9090 jest . clearAllMocks ( ) ;
9191
@@ -96,7 +96,7 @@ describe('Persistence writers', () => {
9696 expect ( mockMPInstance . _Persistence . setProductStorage ) . not . toHaveBeenCalled ( ) ;
9797 } ) ;
9898
99- it ( 'should write to localStorage when useCookieStorage = false' , ( ) => {
99+ it ( 'should write to localStorage when useCookieStorage is false' , ( ) => {
100100 store . SDKConfig . useCookieStorage = false ;
101101 jest . clearAllMocks ( ) ;
102102
@@ -108,13 +108,13 @@ describe('Persistence writers', () => {
108108 } ) ;
109109 } ) ;
110110
111- describe ( 'default ( false) ' , ( ) => {
111+ describe ( 'is false by default ' , ( ) => {
112112 beforeEach ( ( ) => {
113113 // default is false
114114 store . webviewBridgeEnabled = false ;
115115 } ) ;
116116
117- it ( 'should write to cookie by default when useCookieStorage = true' , ( ) => {
117+ it ( 'should write to cookie by default when useCookieStorage is true' , ( ) => {
118118 store . SDKConfig . useCookieStorage = true ;
119119 jest . clearAllMocks ( ) ;
120120
@@ -126,7 +126,7 @@ describe('Persistence writers', () => {
126126 expect ( mockMPInstance . _Persistence . setProductStorage ) . not . toHaveBeenCalled ( ) ;
127127 } ) ;
128128
129- it ( 'should write to localStorage by default when useCookieStorage = false' , ( ) => {
129+ it ( 'should write to localStorage by default when useCookieStorage is false' , ( ) => {
130130 store . SDKConfig . useCookieStorage = false ;
131131 jest . clearAllMocks ( ) ;
132132
@@ -139,7 +139,7 @@ describe('Persistence writers', () => {
139139 } ) ;
140140 } ) ;
141141
142- it ( 'should NOT write to storage when webviewBridgeEnabled = true' , ( ) => {
142+ it ( 'should NOT write to storage when webviewBridgeEnabled is true' , ( ) => {
143143 store . setNoFunctional ( false ) ;
144144 store . webviewBridgeEnabled = true ;
145145 store . SDKConfig . useCookieStorage = true ;
0 commit comments