-
Notifications
You must be signed in to change notification settings - Fork 202
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clarified the development and tests md:
- Completed the "git clone" example. - Added instructions to run "autogen.sh" before "make venv". - Removed optional "git clean" command because it was found to be unnecessary. The Makefile gets regenerated anyway. - Added "Testing"-section to doc/development.md because tests are optional for just building VDSM. - Moved optional "configure" to Advanced-section because it's very rare that some parameters really need to be adjusted. - Fixed broken "tox" example where the search path wasn'n specified resulting in too many tests being collected. - Gave test examples for different modules because some need the explicit search path when passing arguments to pytest and some don't. - Added --no-cov to examples for partial tests because the coverage warning is useless in those cases. - Used multiple arguments in PYTEST_ADDOPTS to show how it's done. - Simplified internal links to not be relative. - Added warning about switching VDSM to maintenance mode before upgrading it. Signed-off-by: Rob Linden [email protected]
- Loading branch information
Showing
2 changed files
with
77 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,13 +2,6 @@ | |
|
||
## Environment setup | ||
|
||
Fork the project on https://github.com/oVirt/vdsm. | ||
|
||
Clone your fork: | ||
|
||
sudo dnf install -y git | ||
[email protected]:{user}/vdsm.git | ||
|
||
Enable oVirt packages for Fedora: | ||
|
||
sudo dnf copr enable -y nsoffer/ioprocess-preview | ||
|
@@ -24,36 +17,67 @@ Update the system after enabling all repositories: | |
|
||
sudo dnf update -y | ||
|
||
Fork the project on https://github.com/oVirt/vdsm. | ||
|
||
Clone your fork: | ||
|
||
sudo dnf install -y git | ||
git clone [email protected]:{your_username}/vdsm.git | ||
|
||
Install additional packages for Fedora, CentOS, and RHEL: | ||
|
||
sudo dnf install -y `cat automation/check-patch.packages` | ||
|
||
Create virtual environment for vdsm: | ||
Generate the Makefile (and configure script): | ||
|
||
./autogen.sh --system --enable-timestamp | ||
|
||
Now you can create the virtual environment | ||
(https://docs.python.org/3/library/venv.html), which is necessary to run the | ||
tests later. This needs to be done only once: | ||
|
||
make venv | ||
|
||
|
||
## Building Vdsm | ||
|
||
To configure sources (run `./configure --help` to see configuration options): | ||
Before building, it is recommended to recreate the Makefile because it | ||
contains version numbers, which might have changed by updating the local | ||
repository: | ||
|
||
git clean -xfd | ||
./autogen.sh --system --enable-timestamp | ||
make | ||
|
||
To test Vdsm (refer to tests/README for further tests information): | ||
To build Vdsm: | ||
|
||
make check | ||
make | ||
|
||
To create an RPM: | ||
To create the RPMs: | ||
|
||
make rpm | ||
|
||
To upgrade your system with local build's RPM: | ||
To upgrade your system with local build's RPM (before you do this you should | ||
activate maintenance mode for Vdsm): | ||
|
||
make upgrade | ||
|
||
|
||
## Running the tests | ||
|
||
To run tests, first enter the virtual environment: | ||
|
||
source ~/.venv/vdsm/bin/activate | ||
|
||
Then start some tests with tox, for example the networking tests: | ||
|
||
tox -e network | ||
|
||
To exit the virtual environment afterwards: | ||
|
||
deactivate | ||
|
||
For more information about testing see [/tests/README.md](/tests/README.md). | ||
|
||
|
||
## Making new releases | ||
|
||
Release process of Vdsm version `VERSION` consists of the following | ||
|
@@ -89,4 +113,10 @@ merged, we need to test them on all supported distributions and | |
architectures. | ||
|
||
When you push patches to GitHub, CI will run its tests according to the | ||
configuration in the `.github/workflows/ci.yml` file. | ||
configuration in the `.github/workflows/ci.yml` file. | ||
|
||
|
||
## Advanced Configuration | ||
|
||
Before running `make` you could use `./configure` to set some (rarely used) options. | ||
To see the list of options: `./configure -h`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters