Add in a variety of files that were mistakenly not commited from the patches
that were originally applied.



git-svn-id: http://test.kernel.org/svn/autotest/trunk@1643 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/client/bin/kernel_versions_unittest.py b/client/bin/kernel_versions_unittest.py
new file mode 100755
index 0000000..fc21a65
--- /dev/null
+++ b/client/bin/kernel_versions_unittest.py
@@ -0,0 +1,87 @@
+#!/usr/bin/python2.4
+import unittest
+from kernel_versions import *
+
+
+class kernel_versions_test(unittest.TestCase):
+
+	def increases(self, kernels):
+		for i in xrange(len(kernels)-1):
+			k1 = kernels[i]
+			k2 = kernels[i+1]
+			ek1 = version_encode(k1)
+			ek2 = version_encode(k2)
+			self.assert_(ek1 < ek2, 
+				'%s (-> %s)  should sort <  %s (-> %s)'
+				% (k1, ek1, k2, ek2) )
+
+
+	def test_version_encode(self):
+		series1 = [
+			'2.6',
+			'2.6.0',
+			'2.6.1-rc1',
+			'2.6.1-rc1_fix',
+			'2.6.1-rc1_patch',
+			'2.6.1-rc9',
+			'2.6.1-rc9-mm1',
+			'2.6.1-rc9-mm2',
+			'2.6.1-rc10',
+			'2.6.1-rc98',
+			'2.6.1',
+			'2.6.1_patch',
+			'2.6.9',
+			'2.6.10',
+			'2.6.99',
+			'2.7',
+			'2.9.99',
+			'2.10.0',
+			'99.99.99',
+			'UNKNOWN',
+			]
+		self.increases(series1)
+		self.increases(['pathX'+k for k in series1])
+		series2 = [
+			'2.6.18-smp-220',
+			'2.6.18-smp-220.0',
+			'2.6.18-smp-220.1_rc1',
+			'2.6.18-smp-220.1_rc1_fix',
+			'2.6.18-smp-220.1_rc1_patch',
+			'2.6.18-smp-220.1_rc9',
+			'2.6.18-smp-220.1_rc9_mm1',
+			'2.6.18-smp-220.1_rc9_mm2',
+			'2.6.18-smp-220.1_rc10',
+			'2.6.18-smp-220.1_rc98',
+			'2.6.18-smp-220.1',
+			'2.6.18-smp-220.1_patch',
+			'2.6.18-smp-220.9',
+			'2.6.18-smp-220.10',
+			'2.6.18-smp-220.99',
+			'2.6.18-smp-221',
+			'UNKNOWN',
+			]
+		self.increases(series2)
+		self.increases(['pathX'+k for k in series2])
+
+
+	releases    = ['2.6.1'      , '2.6.18-smp-220.0'   ]
+	candidates  = ['2.6.1-rc1'  , '2.6.18-smp-220.0_rc1']
+	experiments = ['2.6.1-patch', '2.6.1-rc1_patch', 
+			'2.6.18-smp-220.0_patch', 'UNKNOWN']
+
+	def test_is_released_kernel(self):
+		for v in self.releases:
+			self.assert_(    is_released_kernel(v))
+		for v in self.candidates + self.experiments:
+			self.assert_(not is_released_kernel(v))
+
+
+	def test_is_release_candidate(self):
+		for v in self.releases + self.candidates:
+			self.assert_(    is_release_candidate(v))
+		for v in self.experiments:
+			self.assert_(not is_release_candidate(v))
+
+
+if  __name__ == "__main__":
+	unittest.main()
diff --git a/client/samples/soft_reboot b/client/samples/soft_reboot
new file mode 100644
index 0000000..c5d6727
--- /dev/null
+++ b/client/samples/soft_reboot
@@ -0,0 +1,24 @@
+TIME = 'MEDIUM'
+DOC = """\
+This test will reboot the machine ITERATIONS number of times.  Note that if you
+use this, you'll need to use the step engine for any tests that occur after
+this one.  This means that this may not play well when run from the autotest
+front end."""
+
+
+ITERATIONS = 5
+
+tries = job.get_state('soft_reboot_tries', 0) + 1
+job.set_state("soft_reboot_tries", tries)
+
+if tries < ITERATIONS:
+	import sys
+	this_functions_name = sys._getframe().f_code.co_name
+	if this_functions_name != "?":
+		# If we're not in a function (i.e. we get "?") then we're
+		# not using the step engine and thus no next step is
+		# necessary
+		job.next_step_prepend(this_functions_name) 
+
+if tries <= ITERATIONS:
+	job.reboot()
diff --git a/client/tests/barriertest/control b/client/tests/barriertest/control
new file mode 100644
index 0000000..da594bf
--- /dev/null
+++ b/client/tests/barriertest/control
@@ -0,0 +1,9 @@
+AUTHOR = "Autotest Team"
+TIME = "MEDIUM"
+NAME = "Barrier Test"
+TEST_TYPE = "client"
+TEST_CATEGORY = "Functional"
+TEST_CLASS = "Stress"
+DOC = """\
+Stub information needs to be updated!
+"""
diff --git a/client/tests/selftest/control b/client/tests/selftest/control
new file mode 100644
index 0000000..e864260
--- /dev/null
+++ b/client/tests/selftest/control
@@ -0,0 +1,9 @@
+AUTHOR = "Autotest Team"
+TIME = "MEDIUM"
+NAME = "Self Test"
+TEST_TYPE = "client"
+TEST_CATEGORY = "Functional"
+TEST_CLASS = "Stress"
+DOC = """\
+Stub information needs to be updated!
+"""