spidyDev commented on a change in pull request #11390: [MXNET-23] add README 
for test directory
URL: https://github.com/apache/incubator-mxnet/pull/11390#discussion_r197912493
 
 

 ##########
 File path: tests/README.md
 ##########
 @@ -0,0 +1,45 @@
+# Testing MXNET
+
+## Running CPP Tests
+
+1. Install [cmake](https://cmake.org/install/)
+1. Create a build directory in the root of the mxnet project
+    ```
+    mkdir build
+    cd build
+    ```
+1. Generate your Makefile and build along with the tests with cmake (specify 
appropraite flags)
+    ```
+    cmake -DUSE_CUDNN=ON -DUSE_CUDA=ON -DUSE_MKLDNN=ON -DBLAS=Open 
-DCMAKE_BUILD_TYPE=Debug .. && make
+    ```
+1.  Run tests
+    ```
+    ctest --verbose
+    ```
+
+1. The following will run all the tests the in `cpp` directory. To run just 
your test file replace the following in your `tests/CMakeLists.txt`
+    ```
+    file(GLOB_RECURSE UNIT_TEST_SOURCE "cpp/*.cc" "cpp/*.h")
+    ```
+    with
+    ```
+    file(GLOB_RECURSE UNIT_TEST_SOURCE "cpp/test_main.cc" "cpp/{YOUR TEST 
FILE}")
 
 Review comment:
   Just to be clear :  
   {COMPLETE PATH TO YOUR TEST FILE}

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to