From e0a41b4e4d05686601ca11be8446a9261df150dd Mon Sep 17 00:00:00 2001 From: Paul Moss Date: Thu, 4 Apr 2019 15:26:49 -0400 Subject: [PATCH] updated grunt test --- types/grunt/grunt-tests.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/types/grunt/grunt-tests.ts b/types/grunt/grunt-tests.ts index 7dd6dcf47c..001b94a739 100644 --- a/types/grunt/grunt-tests.ts +++ b/types/grunt/grunt-tests.ts @@ -139,3 +139,16 @@ let myTest = function (grunt: IGrunt) { cwd: '.' }, '*.ts'); } +// test to check process function assignment. +let mytest = function(grunt: IGrunt) { + const opt:grunt.file.IFileWriteStringOption = { + encoding: grunt.file.defaultEncoding, + process: (contents: string, srcPath: string, destPath: string): string | boolean => { + grunt.log.writeln('"file source path"' + srcPath); + grunt.log.writeln('"file destination path"' + destPath); + // return false so no actual copying takes place + return false; + } + } + grunt.file.copy('./test.file',"./testcopy.file", opt); +}