From 55d146696dba1c2d5a1e8dbe7411dcd79bf49080 Mon Sep 17 00:00:00 2001
From: Thorge Petersen <petersen@rz.uni-kiel.de>
Date: Mon, 5 Jun 2023 08:54:16 +0200
Subject: [PATCH] Added basic information on how to run the tests and fixes for
 md linter

---
 README.md | 44 +++++++++++++++++++++++++++++++++++---------
 1 file changed, 35 insertions(+), 9 deletions(-)

diff --git a/README.md b/README.md
index bd9f83c3..2e07b258 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,7 @@
 # ckanext-odsh
 
-This CKAN extension provides custom features and the layout of the Open Data Portal Schleswig-Holstein.
+This CKAN extension provides custom features and the layout of the Open Data Portal
+Schleswig-Holstein.
 
 ## Table of Contents
 
@@ -32,24 +33,27 @@ This project requires the following CKAN extensions to work properly:
 
 To install ckanext-odsh:
 
-1. Activate your CKAN virtual environment, for example::
+1. Activate your CKAN virtual environment, for example:
 
     ```sh
     . /usr/lib/ckan/default/bin/activate
     ```
 
-2. Install the ckanext-odsh Python package into your virtual environment::
+2. Install the ckanext-odsh Python package into your virtual environment:
 
     ```sh
     pip install https://code.schleswig-holstein.de/opendata/ckanext-odsh.git
     ```
 
-3. Add `odsh` to the `ckan.plugins` setting in your CKAN config file (by default the config file is located at `/etc/ckan/default/production.ini`).
+3. Add `odsh` to the `ckan.plugins` setting in your CKAN config file (by default
+the config file is located at `/etc/ckan/default/production.ini`).
 
-   You may also add `odsh_autocomplete`, `odsh_dcat_harvest`, `kiel_harvester` and `statistikamtnord_harvester` to the plugin list, to enable custom functionality, e.g.:
+   You may also add `odsh_autocomplete`, `odsh_collections`, `odsh_dcat_harvest`,
+   `kiel_harvester` and `statistikamtnord_harvester` to the plugin list, to enable
+   custom functionality, e.g.:
 
     ```ini
-    ckan.plugins = 
+    ckan.plugins =
       ckan_harvester
       dcat
       dcatde
@@ -63,6 +67,7 @@ To install ckanext-odsh:
       odsh
       odsh_autocomplete
       odsh_dcat_harvest
+      odsh_collections
       qa
       archiver
       recline_view
@@ -79,7 +84,8 @@ To install ckanext-odsh:
 
 ### Configuration
 
-The extension requires configuration parameters in the CKAN configuration file (e.g., `production.ini`). The following parameters should be set:
+The extension requires configuration parameters in the CKAN configuration file (e.g.,
+`production.ini`). The following parameters should be set:
 
 Parameter | Type | Description
 --------- | ----- | -----------
@@ -98,7 +104,26 @@ ckanext.odsh.is_optional_temporal_start | `boolean` | E.g., `False`.
 
 ### Testing
 
-*Deprecated – will be updated soon.*
+To ensure the quality and functionality of the `ckanext-odsh` extension, a comprehensive
+test suite is provided. You can follow the instructions below to run the tests:
+
+1. Activate the virtual environment associated with your project, for example:
+
+    ```sh
+    . /usr/lib/ckan/default/bin/activate
+    ```
+
+2. From the `ckanext-odsh` base directory, execute the following commands:
+
+    ```sh
+    pytest ckanext/odsh/tests/
+    pytest ckanext/odsh/tests_tpsh/
+    ```
+
+Running these commands will initiate the test suite, which will automatically execute
+various test cases and verify the expected behavior of the extension. The tests are
+organized into two directories: `tests` and `tests_tpsh`, each containing different
+sets of tests.
 
 ## Contributing
 
@@ -121,4 +146,5 @@ who participated in this project.
 
 ## License
 
-This project is licensed under the GNU AFFERO GENERAL PUBLIC LICENSE - see the [LICENSE](./LICENSE) file for details.
+This project is licensed under the GNU AFFERO GENERAL PUBLIC LICENSE - see the
+[LICENSE](./LICENSE) file for details.
-- 
GitLab