[SPARK-9121] [SPARKR] Get rid of the warnings about `no visible global function definition` in SparkR
[SPARK-9121] [SPARKR] Get rid of the warnings about `no visible global function definition` in SparkR

[[SPARK-9121] Get rid of the warnings about `no visible global function definition` in SparkR - ASF JIRA](https://issues.apache.org/jira/browse/SPARK-9121)

## The Result of `dev/lint-r`
[The result of lint-r for SPARK-9121 at the revision:1ddd0f2f1688560f88470e312b72af04364e2d49 when I have sent a PR](https://gist.github.com/yu-iskw/6f55953425901725edf6)

Author: Yu ISHIKAWA <yuu.ishikawa@gmail.com>

Closes #7567 from yu-iskw/SPARK-9121 and squashes the following commits:

c8cfd63 [Yu ISHIKAWA] Fix the typo
b1f19ed [Yu ISHIKAWA] Add a validate statement for local SparkR
1a03987 [Yu ISHIKAWA] Load the `testthat` package in `dev/lint-r.R`, instead of using the full path of function.
3a5e0ab [Yu ISHIKAWA] [SPARK-9121][SparkR] Get rid of the warnings about `no visible global function definition` in SparkR

debugger87/spark,witgo/spark,JerryLead/spark,szhem/spark,wzhfy/spark,hvanhovell/spark,facaiy/spark,nilsgrabbert/spark,ConeyLiu/spark,jrshust/spark,rezasafi/spark,LantaoJin/spark,shubhamchopra/spark,WeichenXu123/spark,milliman/spark,pgandhi999/spark,LantaoJin/spark,jianran/spark,wzhfy/spark,huang1900/spark,chuckchen/spark,ibm-research-ireland/sparkoscope,lxsmnv/spark,jiangxb1987/spark,patrick-nicholson/spark,MLnick/spark,icexelloss/spark,cloud-fan/spark,zero323/spark,mdespriee/spark,akopich/spark,narahari92/spark,map222/spark,HyukjinKwon/spark,panfengfeng/spark,zhouyejoe/spark,lvdongr/spark,actuaryzhang/spark,rezasafi/spark,mike0sv/spark,witgo/spark,spark-test/spark,witgo/spark,BryanCutler/spark,aray/spark,lxsmnv/spark,ddna1021/spark,setjet/spark,yanboliang/spark,jlopezmalla/spark,apache/spark,bdrillard/spark,saltstar/spark,mike0sv/spark,akopich/spark,skonto/spark,LantaoJin/spark,michalsenkyr/spark,holdenk/spark,rikima/spark,tengpeng/spark,ueshin/apache-spark,mzl9039/spark,gengliangwang/spark,rezasafi/spark,ConeyLiu/spark,poffuomo/spark,gioenn/xSpark,liyichao/spark,cin/spark,adrian-ionescu/apache-spark,taroplus/spark,UndeadBaneGitHub/spark,Aegeaner/spark,joseph-torres/spark,SHASHANKB/spark,goldmedal/spark,kevinyu98/spark,SHASHANKB/spark,caneGuy/spark,tejasapatil/spark,ibm-research-ireland/sparkoscope,rekhajoshm/spark,SnappyDataInc/spark,shuangshuangwang/spark,LantaoJin/spark,jiangxb1987/spark,ajaysaini725/spark,kiszk/spark,bdrillard/spark,stanzhai/spark,SnappyDataInc/spark,kissmetrics/spark,kimoonkim/spark,alunarbeach/spark,1haodian/spark,mdespriee/spark,szhem/spark,shaneknapp/spark,jkbradley/spark,ptkool/spark,liyichao/spark,dbtsai/spark,lxsmnv/spark,ddna1021/spark,brad-kaiser/spark,sureshthalamati/spark,dhruve/spark,darionyaphet/spark,liutang123/spark,zzcclp/spark,lxsmnv/spark,JoshRosen/spark,byakuinss/spark,rezasafi/spark,guoxiaolongzte/spark,dbtsai/spark,srowen/spark,wzhfy/spark,hhbyyh/spark,aosagie/spark,akopich/spark,pgandhi999/spark,liutang123/spark,taroplus/spark,gioenn/xSpark,esi-mineset/spark,ajaysaini725/spark,kevinyu98/spark,dongjoon-hyun/spark,eyalfa/spark,goldmedal/spark,zhouyejoe/spark,tejasapatil/spark,jrshust/spark,kissmetrics/spark,caneGuy/spark,caneGuy/spark,apache-spark-on-k8s/spark,Aegeaner/spark,sachintyagi22/spark,aray/spark,byakuinss/spark,srowen/spark,ptkool/spark,joseph-torres/spark,witgo/spark,skonto/spark,publicRoman/spark,mzl9039/spark,Panos-Bletsos/spark-cost-model-optimizer,map222/spark,WindCanDie/spark,JerryLead/spark,michalsenkyr/spark,UndeadBaneGitHub/spark,lvdongr/spark,rekhajoshm/spark,dongjoon-hyun/spark,sahilTakiar/spark,zuotingbing/spark,brad-kaiser/spark,darionyaphet/spark,milliman/spark,kiszk/spark,highfei2011/spark,zero323/spark,sahilTakiar/spark,patrick-nicholson/spark,yanboliang/spark,big-pegasus/spark,ahnqirage/spark,SHASHANKB/spark,ptkool/spark,ueshin/apache-spark,janewangfb/spark,kimoonkim/spark,dhruve/spark,cin/spark,brad-kaiser/spark,debugger87/spark,actuaryzhang/spark,wzhfy/spark,esi-mineset/spark,stanzhai/spark,gioenn/xSpark,holdenk/spark,hhbyyh/spark,SHASHANKB/spark,UndeadBaneGitHub/spark,rezasafi/spark,panfengfeng/spark,ericvandenbergfb/spark,esi-mineset/spark,aokolnychyi/spark,zuotingbing/spark,mdespriee/spark,kevinyu98/spark,huang1900/spark,hvanhovell/spark,highfei2011/spark,michalsenkyr/spark,szhem/spark,rezasafi/spark,cin/spark,jianran/spark,aokolnychyi/spark,publicRoman/spark,ajaysaini725/spark,eyalfa/spark,zhouyejoe/spark,markhamstra/spark,ibm-research-ireland/sparkoscope,andrewor14/spark,dhruve/spark,Panos-Bletsos/spark-cost-model-optimizer,jrshust/spark,jkbradley/spark,pronix/spark,nlalevee/spark,liyichao/spark,xflin/spark,Aegeaner/spark,skonto/spark,patrick-nicholson/spark,jiangxb1987/spark,goldmedal/spark,guoxiaolongzte/spark,michalsenkyr/spark,sureshthalamati/spark,SnappyDataInc/spark,pronix/spark,aosagie/spark,minixalpha/spark,tejasapatil/spark,andrewor14/spark,liyichao/spark,nchammas/spark,ron8hu/spark,ueshin/apache-spark,debugger87/spark,bdrillard/spark,HyukjinKwon/spark,mdespriee/spark,janewangfb/spark,setjet/spark,jkbradley/spark,srowen/spark,shubhamchopra/spark,highfei2011/spark,facaiy/spark,xuanyuanking/spark,ajaysaini725/spark,mzl9039/spark,tengpeng/spark,dbtsai/spark,aray/spark,kiszk/spark,debugger87/spark,mike0sv/spark,esi-mineset/spark,1haodian/spark,publicRoman/spark,sachintyagi22/spark,ueshin/apache-spark,icexelloss/spark,chuckchen/spark,caneGuy/spark,JoshRosen/spark,bOOm-X/spark,markhamstra/spark,mzl9039/spark,ioana-delaney/spark,janewangfb/spark,nilsgrabbert/spark,pronix/spark,ibm-research-ireland/sparkoscope,mahak/spark,MLnick/spark,sahilTakiar/spark,Panos-Bletsos/spark-cost-model-optimizer,ptkool/spark,jrshust/spark,1haodian/spark,zuotingbing/spark,vinodkc/spark,apache-spark-on-k8s/spark,cloud-fan/spark,spark-test/spark,sahilTakiar/spark,esi-mineset/spark,apache/spark,gengliangwang/spark,byakuinss/spark,holdenk/spark,minixalpha/spark,pronix/spark,ahnqirage/spark,tengpeng/spark,akopich/spark,zero323/spark,panfengfeng/spark,saturday-shi/spark,panfengfeng/spark,kimoonkim/spark,metamx/spark,holdenk/spark,sachintyagi22/spark,ddna1021/spark,ahnqirage/spark,lvdongr/spark,markhamstra/spark,brad-kaiser/spark,witgo/spark,HyukjinKwon/spark,WindCanDie/spark,bOOm-X/spark,loneknightpy/spark,Aegeaner/spark,dbtsai/spark,liutang123/spark,pgandhi999/spark,kissmetrics/spark,WindCanDie/spark,ioana-delaney/spark,actuaryzhang/spark,milliman/spark,apache/spark,stanzhai/spark,icexelloss/spark,WeichenXu123/spark,HyukjinKwon/spark,chuckchen/spark,SHASHANKB/spark,rednaxelafx/apache-spark,nilsgrabbert/spark,Aegeaner/spark,jlopezmalla/spark,milliman/spark,milliman/spark,haowu80s/spark,liutang123/spark,ron8hu/spark,holdenk/spark,brad-kaiser/spark,andrewor14/spark,narahari92/spark,dhruve/spark,publicRoman/spark,shuangshuangwang/spark,nlalevee/spark,aosagie/spark,mzl9039/spark,SHASHANKB/spark,zzcclp/spark,SnappyDataInc/spark,bravo-zhang/spark,nlalevee/spark,setjet/spark,ConeyLiu/spark,kevinyu98/spark,MLnick/spark,adrian-ionescu/apache-spark,someorz/spark,maropu/spark,WeichenXu123/spark,ericvandenbergfb/spark,joseph-torres/spark,rezasafi/spark,big-pegasus/spark,shuangshuangwang/spark,kissmetrics/spark,saturday-shi/spark,sureshthalamati/spark,MLnick/spark,1haodian/spark,zzcclp/spark,minixalpha/spark,markhamstra/spark,UndeadBaneGitHub/spark,spark-test/spark,hhbyyh/spark,publicRoman/spark,ioana-delaney/spark,LantaoJin/spark,goldmedal/spark,apache/spark,facaiy/spark,ahnqirage/spark,HyukjinKwon/spark,rikima/spark,jrshust/spark,saltstar/spark,tejasapatil/spark,ibm-research-ireland/sparkoscope,zero323/spark,michalsenkyr/spark,kevinyu98/spark,rikima/spark,xflin/spark,wangyum/spark,xflin/spark,patrick-nicholson/spark,someorz/spark,skonto/spark,JerryLead/spark,rednaxelafx/apache-spark,big-pegasus/spark,shaneknapp/spark,Panos-Bletsos/spark-cost-model-optimizer,skonto/spark,1haodian/spark,cin/spark,jkbradley/spark,hvanhovell/spark,loneknightpy/spark,srowen/spark,facaiy/spark,aray/spark,kimoonkim/spark,dbtsai/spark,matthewfranglen/spark,xuanyuanking/spark,jlopezmalla/spark,SnappyDataInc/spark,techaddict/spark,sahilTakiar/spark,hhbyyh/spark,rednaxelafx/apache-spark,BryanCutler/spark,ddna1021/spark,janewangfb/spark,setjet/spark,shaneknapp/spark,jlopezmalla/spark,Panos-Bletsos/spark-cost-model-optimizer,techaddict/spark,taroplus/spark,tengpeng/spark,SnappyDataInc/spark,caneGuy/spark,aray/spark,kiszk/spark,dhruve/spark,maropu/spark,HyukjinKwon/spark,haowu80s/spark,szhem/spark,mzl9039/spark,ericvandenbergfb/spark,wzhfy/spark,witgo/spark,zuotingbing/spark,apache-spark-on-k8s/spark,BryanCutler/spark,ddna1021/spark,huang1900/spark,brad-kaiser/spark,wangyum/spark,bravo-zhang/spark,JerryLead/spark,srowen/spark,huang1900/spark,ericvandenbergfb/spark,xuanyuanking/spark,alunarbeach/spark,someorz/spark,ajaysaini725/spark,SnappyDataInc/spark,zero323/spark,hhbyyh/spark,Aegeaner/spark,big-pegasus/spark,vinodkc/spark,nilsgrabbert/spark,zhouyejoe/spark,tengpeng/spark,JerryLead/spark,dbtsai/spark,kimoonkim/spark,gioenn/xSpark,kiszk/spark,darionyaphet/spark,sureshthalamati/spark,taroplus/spark,MLnick/spark,narahari92/spark,sachintyagi22/spark,ddna1021/spark,Panos-Bletsos/spark-cost-model-optimizer,lvdongr/spark,xuanyuanking/spark,shaneknapp/spark,liutang123/spark,rednaxelafx/apache-spark,huang1900/spark,aokolnychyi/spark,bOOm-X/spark,stanzhai/spark,jiangxb1987/spark,nchammas/spark,zzcclp/spark,ConeyLiu/spark,aokolnychyi/spark,lvdongr/spark,taroplus/spark,wangmiao1981/spark,mahak/spark,xuanyuanking/spark,setjet/spark,darionyaphet/spark,hvanhovell/spark,byakuinss/spark,maropu/spark,eyalfa/spark,minixalpha/spark,ajaysaini725/spark,maropu/spark,byakuinss/spark,mike0sv/spark,wangmiao1981/spark,andrewor14/spark,ajaysaini725/spark,eyalfa/spark,chuckchen/spark,zero323/spark,loneknightpy/spark,ahnqirage/spark,nlalevee/spark,yanboliang/spark,xflin/spark,rekhajoshm/spark,sureshthalamati/spark,darionyaphet/spark,michalsenkyr/spark,lvdongr/spark,apache-spark-on-k8s/spark,xflin/spark,yanboliang/spark,sahilTakiar/spark,liyichao/spark,shubhamchopra/spark,joseph-torres/spark,ioana-delaney/spark,ahnqirage/spark,sachintyagi22/spark,andrewor14/spark,jlopezmalla/spark,jlopezmalla/spark,apache-spark-on-k8s/spark,narahari92/spark,maropu/spark,maropu/spark,saturday-shi/spark,UndeadBaneGitHub/spark,saltstar/spark,rednaxelafx/apache-spark,bOOm-X/spark,jianran/spark,kimoonkim/spark,zhouyejoe/spark,setjet/spark,someorz/spark,narahari92/spark,szhem/spark,nchammas/spark,jlopezmalla/spark,szhem/spark,icexelloss/spark,vinodkc/spark,bravo-zhang/spark,wangmiao1981/spark,loneknightpy/spark,lxsmnv/spark,maropu/spark,jiangxb1987/spark,poffuomo/spark,shubhamchopra/spark,mahak/spark,ericvandenbergfb/spark,Panos-Bletsos/spark-cost-model-optimizer,nchammas/spark,shaneknapp/spark,liutang123/spark,wangyum/spark,rekhajoshm/spark,mike0sv/spark,vinodkc/spark,highfei2011/spark,ioana-delaney/spark,gengliangwang/spark,metamx/spark,jrshust/spark,1haodian/spark,saturday-shi/spark,wangyum/spark,eyalfa/spark,xuanyuanking/spark,ddna1021/spark,darionyaphet/spark,ptkool/spark,zuotingbing/spark,tejasapatil/spark,witgo/spark,gengliangwang/spark,poffuomo/spark,hhbyyh/spark,lxsmnv/spark,brad-kaiser/spark,adrian-ionescu/apache-spark,milliman/spark,taroplus/spark,chuckchen/spark,apache-spark-on-k8s/spark,rikima/spark,facaiy/spark,wangyum/spark,techaddict/spark,facaiy/spark,icexelloss/spark,jiangxb1987/spark,shubhamchopra/spark,sachintyagi22/spark,map222/spark,ConeyLiu/spark,minixalpha/spark,techaddict/spark,Aegeaner/spark,apache/spark,metamx/spark,map222/spark,WeichenXu123/spark,vinodkc/spark,dbtsai/spark,gengliangwang/spark,aokolnychyi/spark,alunarbeach/spark,nlalevee/spark,guoxiaolongzte/spark,MLnick/spark,andrewor14/spark,ueshin/apache-spark,bravo-zhang/spark,saltstar/spark,bdrillard/spark,kissmetrics/spark,jianran/spark,tejasapatil/spark,zzcclp/spark,akopich/spark,nilsgrabbert/spark,shuangshuangwang/spark,JerryLead/spark,JoshRosen/spark,loneknightpy/spark,cloud-fan/spark,WeichenXu123/spark,poffuomo/spark,highfei2011/spark,bdrillard/spark,cloud-fan/spark,actuaryzhang/spark,guoxiaolongzte/spark,pronix/spark,icexelloss/spark,dongjoon-hyun/spark,holdenk/spark,ioana-delaney/spark,mahak/spark,guoxiaolongzte/spark,lxsmnv/spark,kiszk/spark,panfengfeng/spark,gioenn/xSpark,gengliangwang/spark,gengliangwang/spark,akopich/spark,someorz/spark,sureshthalamati/spark,skonto/spark,eyalfa/spark,bravo-zhang/spark,metamx/spark,ConeyLiu/spark,BryanCutler/spark,panfengfeng/spark,jkbradley/spark,markhamstra/spark,UndeadBaneGitHub/spark,huang1900/spark,hhbyyh/spark,apache-spark-on-k8s/spark,rikima/spark,bravo-zhang/spark,ioana-delaney/spark,pgandhi999/spark,poffuomo/spark,michalsenkyr/spark,jianran/spark,someorz/spark,hvanhovell/spark,ron8hu/spark,haowu80s/spark,ron8hu/spark,debugger87/spark,saturday-shi/spark,markhamstra/spark,janewangfb/spark,debugger87/spark,bravo-zhang/spark,liutang123/spark,zuotingbing/spark,wzhfy/spark,esi-mineset/spark,shaneknapp/spark,jkbradley/spark,aosagie/spark,someorz/spark,zhouyejoe/spark,akopich/spark,yanboliang/spark,stanzhai/spark,holdenk/spark,rednaxelafx/apache-spark,xflin/spark,highfei2011/spark,shuangshuangwang/spark,loneknightpy/spark,kissmetrics/spark,milliman/spark,map222/spark,ron8hu/spark,hvanhovell/spark,dongjoon-hyun/spark,SHASHANKB/spark,wangyum/spark,JoshRosen/spark,mdespriee/spark,big-pegasus/spark,cloud-fan/spark,zuotingbing/spark,huang1900/spark,eyalfa/spark,chuckchen/spark,alunarbeach/spark,saltstar/spark,aosagie/spark,cin/spark,patrick-nicholson/spark,bOOm-X/spark,aosagie/spark,WindCanDie/spark,narahari92/spark,yanboliang/spark,nilsgrabbert/spark,mzl9039/spark,gioenn/xSpark,aosagie/spark,mdespriee/spark,JoshRosen/spark,techaddict/spark,rekhajoshm/spark,adrian-ionescu/apache-spark,spark-test/spark,setjet/spark,ptkool/spark,apache/spark,zero323/spark,wangmiao1981/spark,chuckchen/spark,wangyum/spark,yanboliang/spark,lvdongr/spark,tengpeng/spark,kevinyu98/spark,debugger87/spark,zhouyejoe/spark,map222/spark,goldmedal/spark,loneknightpy/spark,poffuomo/spark,darionyaphet/spark,WeichenXu123/spark,cloud-fan/spark,haowu80s/spark,aokolnychyi/spark,mahak/spark,saltstar/spark,saltstar/spark,nchammas/spark,nchammas/spark,rednaxelafx/apache-spark,dongjoon-hyun/spark,kiszk/spark,alunarbeach/spark,skonto/spark,srowen/spark,hvanhovell/spark,shuangshuangwang/spark,pgandhi999/spark,HyukjinKwon/spark,map222/spark,publicRoman/spark,mike0sv/spark,haowu80s/spark,big-pegasus/spark,janewangfb/spark,LantaoJin/spark,sachintyagi22/spark,apache/spark,MLnick/spark,narahari92/spark,BryanCutler/spark,ptkool/spark,JoshRosen/spark,dongjoon-hyun/spark,metamx/spark,nlalevee/spark,bOOm-X/spark,aray/spark,actuaryzhang/spark,caneGuy/spark,icexelloss/spark,adrian-ionescu/apache-spark,bOOm-X/spark,LantaoJin/spark,actuaryzhang/spark,guoxiaolongzte/spark,spark-test/spark,shuangshuangwang/spark,alunarbeach/spark,stanzhai/spark,ueshin/apache-spark,ConeyLiu/spark,joseph-torres/spark,metamx/spark,shaneknapp/spark,taroplus/spark,saturday-shi/spark,rikima/spark,mahak/spark,ibm-research-ireland/sparkoscope,joseph-torres/spark,mahak/spark,spark-test/spark,panfengfeng/spark,pronix/spark,BryanCutler/spark,wangmiao1981/spark,cloud-fan/spark,rekhajoshm/spark,highfei2011/spark,WindCanDie/spark,JoshRosen/spark,sahilTakiar/spark,WeichenXu123/spark,kissmetrics/spark,dongjoon-hyun/spark,big-pegasus/spark,metamx/spark,ron8hu/spark,bdrillard/spark,esi-mineset/spark,sureshthalamati/spark,WindCanDie/spark,JerryLead/spark,patrick-nicholson/spark,jianran/spark,adrian-ionescu/apache-spark,adrian-ionescu/apache-spark,publicRoman/spark,patrick-nicholson/spark,byakuinss/spark,srowen/spark,facaiy/spark,UndeadBaneGitHub/spark,guoxiaolongzte/spark,joseph-torres/spark,vinodkc/spark,wangmiao1981/spark,nilsgrabbert/spark,jianran/spark,shubhamchopra/spark,nchammas/spark,cin/spark,minixalpha/spark,alunarbeach/spark,BryanCutler/spark,tejasapatil/spark,poffuomo/spark,andrewor14/spark,ibm-research-ireland/sparkoscope,goldmedal/spark,liyichao/spark,WindCanDie/spark,wzhfy/spark,tengpeng/spark,actuaryzhang/spark,kevinyu98/spark,ahnqirage/spark,rekhajoshm/spark,vinodkc/spark,cin/spark,techaddict/spark,zzcclp/spark,byakuinss/spark,shubhamchopra/spark,nlalevee/spark,ericvandenbergfb/spark,1haodian/spark,xflin/spark,pgandhi999/spark,gioenn/xSpark,xuanyuanking/spark,rikima/spark,goldmedal/spark,jkbradley/spark,szhem/spark,ron8hu/spark,dhruve/spark,markhamstra/spark,dhruve/spark,liyichao/spark,mike0sv/spark,stanzhai/spark,zzcclp/spark,minixalpha/spark,mdespriee/spark,spark-test/spark,jrshust/spark,kimoonkim/spark,janewangfb/spark,aray/spark,saturday-shi/spark,caneGuy/spark,bdrillard/spark,ueshin/apache-spark,pgandhi999/spark,wangmiao1981/spark,techaddict/spark,haowu80s/spark,jiangxb1987/spark,ericvandenbergfb/spark,aokolnychyi/spark