mk/tools/replace.mk: Add support for `:test' to add tools to TEST_DEPENDS

With this change is now possible to mark tools only needed for testing via:

 USE_TOOLS+= <tool>:test


Index: mk/tools/replace.mk
===================================================================
RCS file: /cvsroot/pkgsrc/mk/tools/replace.mk,v
retrieving revision 1.281
diff -u -p -r1.281 replace.mk
--- mk/tools/replace.mk	7 Jan 2018 11:23:37 -0000	1.281
+++ mk/tools/replace.mk	24 Jan 2018 12:18:10 -0000
@@ -131,6 +131,7 @@ PKG_FAIL_REASON+=	"\`\`bison'' and \`\`b
 #    BOOTSTRAP_DEPENDS:	:bootstrap
 #    TOOL_DEPENDS:	:build (default), :pkgsrc
 #    DEPENDS:		:run
+#    TEST_DEPENDS:	:test
 #
 .for _t_ in ${USE_TOOLS:N*\:*} ${USE_TOOLS:M*\:bootstrap}
 _TOOLS_DEPMETHOD.${_t_:C/:.*//}=	BOOTSTRAP_DEPENDS
@@ -141,6 +142,9 @@ _TOOLS_DEPMETHOD.${_t_:C/:.*//}=	TOOL_DE
 .for _t_ in ${USE_TOOLS:M*\:run}
 _TOOLS_DEPMETHOD.${_t_:C/:.*//}=	DEPENDS
 .endfor
+.for _t_ in ${USE_TOOLS:M*\:test}
+_TOOLS_DEPMETHOD.${_t_:C/:.*//}=	TEST_DEPENDS
+.endfor
 
 .if !empty(_USE_TOOLS:Mbison-yacc)	# bison-yacc > yacc
 .  if defined(_TOOLS_DEPMETHOD.bison-yacc) && \