@@ -222,6 +222,35 @@ describe('lib/main', function () {
222222 assert . isNull ( params . TracingConfig . Mode )
223223 } )
224224
225+ describe ( 'params.Publish' , ( ) => {
226+ describe ( 'boolean' , ( ) => {
227+ it ( 'If true, it is set to true' , ( ) => {
228+ program . publish = true
229+ const params = lambda . _params ( program )
230+ assert . isTrue ( params . Publish )
231+ } )
232+ it ( 'If false, it is set to false' , ( ) => {
233+ program . publish = false
234+ const params = lambda . _params ( program )
235+ assert . isFalse ( params . Publish )
236+ } )
237+ } )
238+
239+ describe ( 'string' , ( ) => {
240+ it ( 'If "true", it is set to true' , ( ) => {
241+ program . publish = 'true'
242+ const params = lambda . _params ( program )
243+ assert . isTrue ( params . Publish )
244+ } )
245+ it ( 'If not "true", it is set to false' , ( ) => {
246+ program . publish = 'false'
247+ assert . isFalse ( lambda . _params ( program ) . Publish )
248+ program . publish = 'aaa'
249+ assert . isFalse ( lambda . _params ( program ) . Publish )
250+ } )
251+ } )
252+ } )
253+
225254 describe ( 'configFile' , ( ) => {
226255 beforeEach ( ( ) => {
227256 // Prep...
0 commit comments