d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# This file and its contents are supplied under the terms of the
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# Common Development and Distribution License ("CDDL"), version 1.0.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# You may only use this file in accordance with the terms of version
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# 1.0 of the CDDL.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# A full copy of the text of the CDDL should have accompanied this
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# source. A copy of the CDDL is also available via the Internet at
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# http://www.illumos.org/license/CDDL.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# Copyright (c) 2012 by Delphix. All rights reserved.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyOS Unit Test Suite README
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy1. Building and installing the OS Unit Test Suite
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy2. Running the OS Unit Test Suite
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy3. Test results
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy--------------------------------------------------------------------------------
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy1. Building and installing the OS Unit Test Suite
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyThe OS Unit Test Suite runs under the testrunner framework (which can be
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyinstalled as pkg:/system/test/testrunner). To build both the OS Unit Test Suite
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyand the testrunner without running a full nightly:
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy build_machine$ bldenv [-d] <your_env_file>
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy build_machine$ cd $SRC/test
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy build_machine$ dmake install
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy build_machine$ cd $SRC/pkg
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy build_machine$ dmake install
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyThen set the publisher on the test machine to point to your repository and
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyinstall the OS Unit Test Suite.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy test_machine# pkg install pkg:/system/test/zfstest
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyNote, the framework will be installed automatically, as the OS Unit Test Suite
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedydepends on it.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy2. Running the OS Unit Test Suite
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyThe pre-requisites for running the OS Unit Test Suite are:
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy - A non-root user with the ability to sudo(1M) to root without a
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy password or the root user must run the test.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyOnce the pre-requisites are satisfied, simply run the ostest script:
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy test_machine$ /opt/os-tests/bin/ostest
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy3. Test results
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyWhile the OS Unit Test Suite is running, one informational line is printed at
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedythe end of each test, and a results summary is printed at the end of the run.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren KennedyThe results summary includes the location of the complete logs, which is of the
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyform /var/tmp/test_results/<ISO 8601 date>.