You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/01/13 12:04:11 UTC

[GitHub] [arrow] AlenkaF commented on a change in pull request #12140: ARROW-14759 [Doc] Steps in making your first PR - test in R

AlenkaF commented on a change in pull request #12140:
URL: https://github.com/apache/arrow/pull/12140#discussion_r783895444



##########
File path: docs/source/developers/guide/step_by_step/testing.rst
##########
@@ -62,29 +62,81 @@ In this section we outline steps needed for unit testing in Arrow.
 
       If the tests start failing, try to recompile
       PyArrow or C++.
-      
+
       .. note::
 
          **Recompiling Cython**
 
          If you only make changes to `.py` files, you do not need to
          recompile PyArrow. However, you should recompile it if you make
          changes in `.pyx` or `.pxd` files.
-        
+
          To do that run this command again:
 
          .. code:: console
 
             $ python setup.py build_ext --inplace
 
       .. note::
-		
+
          **Recompiling C++**
 
          Similarly, you will need to recompile the C++ code if you have
          made changes to any C++ files. In this case,
-         re-run the cmake commands again. 
+         re-run the cmake commands again.
 
    .. tab:: R tests
 
-      .. TODO
+      We use `testthat <https://testthat.r-lib.org/index.html>`_ for unit testing in R. More specifically, we use the `3rd edition of testthat <https://testthat.r-lib.org/articles/third-edition.html>`_. On rare occasions we might want the behaviour of the 2nd edition of testthat, which is indicated by ``testthat::local_edition(2)``.
+
+      **Structure**
+
+      Expect the usual testthat folder structure:
+      .. TODO make sure the format the dir tree below is formatted nicely (maybe as a code block)
+      tests
+        ├── testthat      # unit test files live here
+        └── testthat.R    # runs tests when R CMD check runs (e.g. with `devtools::check()`)

Review comment:
       ```suggestion
         
         .. code-block:: R
         
            tests
              ├── testthat      # unit test files live here
              └── testthat.R    # runs tests when R CMD check runs (e.g. with `devtools::check()`)
   ```
   
   This works well in the html version of the docs.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org