Add plans for all supported shells, reorganize
Create plan for each supported shell, pick relevant tests. Remove Makefile and PURPOSE files, they are no more necessary. Group tests and plans, each under a dedicated directory. Add tags to allow selecting tests for running in a container.
This commit is contained in:
parent
43ffc1fa4a
commit
84319ada68
28 changed files with 58 additions and 212 deletions
|
|
@ -1,64 +0,0 @@
|
|||
# Makefile
|
||||
# Author: Jan Scotka <jscotka@redhat.com>
|
||||
# Location:
|
||||
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2008 Red Hat, Inc.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation, either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be
|
||||
# useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
# PURPOSE. See the GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see http://www.gnu.org/licenses/.
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
||||
TOPLEVEL_NAMESPACE=/CoreOS
|
||||
PACKAGE_NAME=bash
|
||||
RELATIVE_PATH=sanity/func
|
||||
|
||||
export TEST=$(TOPLEVEL_NAMESPACE)/$(PACKAGE_NAME)/$(RELATIVE_PATH)
|
||||
export TESTVERSION=1.0
|
||||
|
||||
BUILT_FILES=
|
||||
|
||||
FILES=$(METADATA) runtest.sh Makefile PURPOSE
|
||||
|
||||
.PHONY: all install download clean
|
||||
|
||||
run: $(FILES) build
|
||||
./runtest.sh
|
||||
|
||||
build: $(BUILT_FILES)
|
||||
chmod a+x ./runtest.sh
|
||||
|
||||
clean:
|
||||
rm -f *~ $(BUILT_FILES)
|
||||
|
||||
|
||||
include /usr/share/rhts/lib/rhts-make.include
|
||||
|
||||
|
||||
$(METADATA): Makefile
|
||||
@touch $(METADATA)
|
||||
@echo "Owner: Jan Scotka <jscotka@redhat.com>" > $(METADATA)
|
||||
@echo "Name: $(TEST)" >> $(METADATA)
|
||||
@echo "Path: $(TEST_DIR)" >> $(METADATA)
|
||||
@echo "TestVersion: $(TESTVERSION)" >> $(METADATA)
|
||||
@echo "Description: Try shell basic functionality" >> $(METADATA)
|
||||
@echo "Type: Sanity" >> $(METADATA)
|
||||
@echo "TestTime: 2h" >> $(METADATA)
|
||||
@echo "RunFor: $(PACKAGE_NAME)" >> $(METADATA)
|
||||
@echo "Requires: $(PACKAGE_NAME)" >> $(METADATA)
|
||||
@echo "License: GPLv2" >> $(METADATA)
|
||||
|
||||
rhts-lint $(METADATA)
|
||||
|
|
@ -1 +0,0 @@
|
|||
Basic test of functions in Bourne-Again SHell, testing purpose for Test Container Project
|
||||
|
|
@ -1,66 +0,0 @@
|
|||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Makefile of /CoreOS/bash/Sanity/login-shell
|
||||
# Description: the test creates user with bash as login shell and verified the user can log in and get th
|
||||
# Author: Martin Kyral <mkyral@redhat.com>
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2016 Red Hat, Inc.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation, either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be
|
||||
# useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
# PURPOSE. See the GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see http://www.gnu.org/licenses/.
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
export TEST=/CoreOS/bash/Sanity/login-shell
|
||||
export TESTVERSION=1.0
|
||||
|
||||
BUILT_FILES=
|
||||
|
||||
FILES=$(METADATA) runtest.sh Makefile PURPOSE script.exp ssh.exp tst.sh
|
||||
|
||||
.PHONY: all install download clean
|
||||
|
||||
run: $(FILES) build
|
||||
./runtest.sh
|
||||
|
||||
build: $(BUILT_FILES)
|
||||
test -x runtest.sh || chmod a+x runtest.sh
|
||||
|
||||
clean:
|
||||
rm -f *~ $(BUILT_FILES)
|
||||
|
||||
|
||||
include /usr/share/rhts/lib/rhts-make.include
|
||||
|
||||
$(METADATA): Makefile
|
||||
@echo "Owner: Martin Kyral <mkyral@redhat.com>" > $(METADATA)
|
||||
@echo "Name: $(TEST)" >> $(METADATA)
|
||||
@echo "TestVersion: $(TESTVERSION)" >> $(METADATA)
|
||||
@echo "Path: $(TEST_DIR)" >> $(METADATA)
|
||||
@echo "Description: the test creates user with bash as login shell and verified the user can log in and get th" >> $(METADATA)
|
||||
@echo "Type: Sanity" >> $(METADATA)
|
||||
@echo "TestTime: 5m" >> $(METADATA)
|
||||
@echo "RunFor: ksh zsh bash dash mksh pdksh" >> $(METADATA)
|
||||
@echo "Requires: bash" >> $(METADATA)
|
||||
@echo "Requires: expect" >> $(METADATA)
|
||||
@echo "Requires: procps-ng" >> $(METADATA)
|
||||
@echo "Requires: passwd" >> $(METADATA)
|
||||
@echo "Requires: openssh-clients openssh-server" >> $(METADATA)
|
||||
@echo "Priority: Normal" >> $(METADATA)
|
||||
@echo "License: GPLv2+" >> $(METADATA)
|
||||
@echo "Confidential: no" >> $(METADATA)
|
||||
@echo "Destructive: no" >> $(METADATA)
|
||||
|
||||
rhts-lint $(METADATA)
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
PURPOSE of /CoreOS/bash/Sanity/login-shell
|
||||
Description: the test creates user with bash as login shell and verified the user can log in and get th
|
||||
Author: Your Name <mkyral@redhat.com>
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
summary: Basic login shell test
|
||||
description: >
|
||||
The test creates user with bash as login shell and
|
||||
verifies that the user can log into the system.
|
||||
tags: [classic]
|
||||
7
plans/bash.fmf
Normal file
7
plans/bash.fmf
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
discover+:
|
||||
filter: component:bash
|
||||
prepare+:
|
||||
package: bash
|
||||
environment:
|
||||
PACKAGES: bash
|
||||
SH_BIN: bash
|
||||
7
plans/dash.fmf
Normal file
7
plans/dash.fmf
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
discover+:
|
||||
filter: component:dash
|
||||
prepare+:
|
||||
package: dash
|
||||
environment:
|
||||
PACKAGES: dash
|
||||
SH_BIN: dash
|
||||
7
plans/ksh.fmf
Normal file
7
plans/ksh.fmf
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
discover+:
|
||||
filter: component:ksh
|
||||
prepare+:
|
||||
package: ksh
|
||||
environment:
|
||||
PACKAGES: ksh
|
||||
SH_BIN: ksh
|
||||
6
plans/main.fmf
Normal file
6
plans/main.fmf
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
discover:
|
||||
how: fmf
|
||||
prepare:
|
||||
how: install
|
||||
execute:
|
||||
how: tmt
|
||||
7
plans/mksh.fmf
Normal file
7
plans/mksh.fmf
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
discover+:
|
||||
filter: component:mksh
|
||||
prepare+:
|
||||
package: mksh
|
||||
environment:
|
||||
PACKAGES: mksh
|
||||
SH_BIN: mksh
|
||||
7
plans/zsh.fmf
Normal file
7
plans/zsh.fmf
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
discover+:
|
||||
filter: component:zsh
|
||||
prepare+:
|
||||
package: zsh
|
||||
environment:
|
||||
PACKAGES: zsh
|
||||
SH_BIN: zsh
|
||||
|
|
@ -1,62 +0,0 @@
|
|||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Makefile of /CoreOS/bash/Sanity/smoke
|
||||
# Description: Basic sanity smoke test
|
||||
# Author: Miroslav Hradilek <mhradile@redhat.com>
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2012 Red Hat, Inc.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation, either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be
|
||||
# useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
# PURPOSE. See the GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see http://www.gnu.org/licenses/.
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
export TEST=/CoreOS/bash/Sanity/smoke
|
||||
export TESTVERSION=1.0
|
||||
|
||||
BUILT_FILES=
|
||||
|
||||
FILES=$(METADATA) runtest.sh Makefile PURPOSE t_alias t_conditionals t_variables
|
||||
|
||||
.PHONY: all install download clean
|
||||
|
||||
run: $(FILES) build
|
||||
./runtest.sh
|
||||
|
||||
build: $(BUILT_FILES)
|
||||
test -x runtest.sh || chmod a+x runtest.sh
|
||||
|
||||
clean:
|
||||
rm -f *~ $(BUILT_FILES)
|
||||
|
||||
|
||||
include /usr/share/rhts/lib/rhts-make.include
|
||||
|
||||
$(METADATA): Makefile
|
||||
@echo "Owner: Miroslav Hradilek <mhradile@redhat.com>" > $(METADATA)
|
||||
@echo "Name: $(TEST)" >> $(METADATA)
|
||||
@echo "TestVersion: $(TESTVERSION)" >> $(METADATA)
|
||||
@echo "Path: $(TEST_DIR)" >> $(METADATA)
|
||||
@echo "Description: Basic sanity smoke test" >> $(METADATA)
|
||||
@echo "Type: Sanity" >> $(METADATA)
|
||||
@echo "TestTime: 5m" >> $(METADATA)
|
||||
@echo "RunFor: bash" >> $(METADATA)
|
||||
@echo "Requires: bash" >> $(METADATA)
|
||||
@echo "Priority: Normal" >> $(METADATA)
|
||||
@echo "License: GPLv2" >> $(METADATA)
|
||||
@echo "Confidential: no" >> $(METADATA)
|
||||
@echo "Destructive: no" >> $(METADATA)
|
||||
|
||||
rhts-lint $(METADATA)
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
PURPOSE of /CoreOS/bash/Sanity/smoke
|
||||
Description: Basic sanity smoke test
|
||||
Author: Miroslav Hradilek <mhradile@redhat.com>
|
||||
|
||||
Performs basic sanity smoke test. Tries to supply commands on a
|
||||
command line, variable assignment and substitution, file
|
||||
expansion, "test" builtin, redirection, pipeline and some control
|
||||
structures.
|
||||
|
|
@ -1,3 +1,3 @@
|
|||
summary: Basic test of functions in Bourne-Again Shell
|
||||
duration: 2h
|
||||
duration: 15m
|
||||
component: [bash, ksh, mksh, zsh]
|
||||
12
tests/login/main.fmf
Normal file
12
tests/login/main.fmf
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
summary: Basic login shell test
|
||||
description: >
|
||||
The test creates user with bash as login shell and
|
||||
verifies that the user can log into the system.
|
||||
Does not run in a container, needs full virtualization.
|
||||
tag: [virtual]
|
||||
require:
|
||||
- expect
|
||||
- procps-ng
|
||||
- passwd
|
||||
- openssh-clients
|
||||
- openssh-server
|
||||
|
|
@ -1,6 +1,7 @@
|
|||
contact: Jakub Heger <jheger@redhat.com>
|
||||
test: ./test.sh
|
||||
framework: beakerlib
|
||||
component: [bash, ksh, mksh, zsh, dash]
|
||||
test: ./runtest.sh
|
||||
duration: 5m
|
||||
tier: 2
|
||||
tags: [classic, container, atomic]
|
||||
tag: [virtual, container]
|
||||
|
|
@ -2,6 +2,7 @@ summary: Verify correct $$ parsing in command substitution
|
|||
description: |
|
||||
Parsing commands break when using $$ in command substitution $(..).
|
||||
Test for https://bugzilla.redhat.com/show_bug.cgi?id=1727952
|
||||
tier: 1
|
||||
|
||||
extra-nitrate: TC#0602870
|
||||
extra-summary: /CoreOS/bash/Regression/bz1727952-Parsing-commands-break-when-using-in-command
|
||||
Loading…
Add table
Add a link
Reference in a new issue