ARROW-17084: [R] Install the package before linting (#13620)
ARROW-17084: [R] Install the package before linting (#13620)

The package should be installed before running `lintr::ling_package()` or `lintr::expect_lint_free()` (our case), otherwise we could encounter some false positives.

See https://github.com/r-lib/lintr/issues/352#issuecomment-587004345 and https://github.com/r-lib/lintr/issues/406#issuecomment-534601141


Authored-by: Dragoș Moldovan-Grünfeld <9c9f9cb3247c58daa0f64b617331eb35608a8fa0@gmail.com>
Signed-off-by: Jonathan Keane <28d17c45cab2bb8b25bea44a915713e26ce37e1b@gmail.com>
kou/arrow,kou/arrow,icexelloss/arrow,apache/arrow,icexelloss/arrow,kou/arrow,kou/arrow,icexelloss/arrow,apache/arrow,kou/arrow,apache/arrow,apache/arrow,apache/arrow,apache/arrow,kou/arrow,icexelloss/arrow,apache/arrow,icexelloss/arrow,kou/arrow,kou/arrow,icexelloss/arrow,kou/arrow,icexelloss/arrow,apache/arrow,icexelloss/arrow,apache/arrow,kou/arrow,icexelloss/arrow,apache/arrow,kou/arrow,kou/arrow,icexelloss/arrow,icexelloss/arrow,apache/arrow,kou/arrow,apache/arrow,icexelloss/arrow,icexelloss/arrow,apache/arrow,kou/arrow,icexelloss/arrow,apache/arrow