2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore#
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# This file and its contents are supplied under the terms of the
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# Common Development and Distribution License ("CDDL"), version 1.0.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# You may only use this file in accordance with the terms of version
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# 1.0 of the CDDL.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore#
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# A full copy of the text of the CDDL should have accompanied this
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# source. A copy of the CDDL is also available via the Internet at
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# http://www.illumos.org/license/CDDL.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore#
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore#
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# Copyright 2014 Garrett D'Amore <garrett@damore.org>
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore# Copyright (c) 2012 by Delphix. All rights reserved.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore#
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amorelibc Unit Test Suite README
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore1. What this Unit Test Suite tests
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore2. Building and installing this Unit Test Suite
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore3. Running this Unit Test Suite
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore4. Test results
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore--------------------------------------------------------------------------------
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore1. What this Unit Test Suite tests
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
538aa54d819fa7751ca82bcc30d4ed8c57ec2ef2Garrett D'AmoreThis Unit Test Suite is for testing various libc interfaces. The suite
538aa54d819fa7751ca82bcc30d4ed8c57ec2ef2Garrett D'Amorewill test both 32 and 64 bit versions, provided that your kernel supports
538aa54d819fa7751ca82bcc30d4ed8c57ec2ef2Garrett D'Amoreboth.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore2. Building and installing this Unit Test Suite
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'AmoreThis Test Suite runs under the testrunner framework (which can be installed
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amoreas pkg:/system/test/testrunner). To build both this Unit Test Suite and the
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amoretestrunner without running a full nightly:
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore build_machine$ bldenv [-d] <your_env_file>
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore build_machine$ cd $SRC/test
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore build_machine$ dmake install
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore build_machine$ cd $SRC/pkg
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore build_machine$ dmake install
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'AmoreThen set the publisher on the test machine to point to your repository and
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amoreinstall the Utils Unit Test Suite.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore test_machine# pkg install pkg:/system/test/libctest
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'AmoreNote, the framework will be installed automatically, as this test suite
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amoredepends on it.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'AmoreAdditionally some text locales are required, specifically, en_US.UTF-8,
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amorede_DE.UTF-8, ja_JP.UTF-8, and ru_RU.UTF-8. Again, these are listed as
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amoredependencies and will be automatically installed.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore3. Running this Unit Test Suite
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'AmoreThe pre-requisites for running the this Unit Test Suite are:
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore - Any user may perform these tests.
538aa54d819fa7751ca82bcc30d4ed8c57ec2ef2Garrett D'Amore - The en_US.UTF-8, en_GB.ISO8859-15, ja_JP.UTF-8, de_DE.UTF-8, and
538aa54d819fa7751ca82bcc30d4ed8c57ec2ef2Garrett D'Amore ru_RU.UTF-8 locales must be installed.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
538aa54d819fa7751ca82bcc30d4ed8c57ec2ef2Garrett D'AmoreOnce the pre-requisites are satisfied, simply run the libctest script:
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
538aa54d819fa7751ca82bcc30d4ed8c57ec2ef2Garrett D'Amore test_machine$ /opt/libc-tests/bin/libctest
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore4. Test results
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amore
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'AmoreWhile the Unit Test Suite is running, one informational line is printed at
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amorethe end of each test, and a results summary is printed at the end of the run.
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'AmoreThe results summary includes the location of the complete logs, which is of the
2d08521bd15501c8370ba2153b9cca4f094979d0Garrett D'Amoreform /var/tmp/test_results/<ISO 8601 date>.