*Description:* Pax is an archiving utility that will read, write, and list the members of an archive file and will copy directory hierarchies. pax operation is independent of the specific archive format and supports a wide variety of different archive formats,like tar,cpio and so on.
*Dependent Binaries:* The pax binaries to be tested are located under */usr/bin/pax* *Approach:* 1.Check for pax,install if not found 2.Create a custom directory hierarchy under */tmp* ,for eg: *mkdir archive * *mkdir archive/d_one * *mkdir archive/d_two * *mkdir archive/d_three * *echo "file 1" > archive/d_one/f_one * *echo "file 2" > archive/d_one/f_two * *echo "file 3" > archive/d_one/f_three * *mkdir archive/d_two/d_four* * * 3.Switches to be tested: * a)pax -w : *creates an archive * b)pax <none> *:List contents of an archive * c)pax -rf :*Extract/read an archive 4. pax can copy directory hierarchies to another location,which is also tested. 5.Compare the obtained outputs with the expected output. *Setup:* 1.Check if pax is installed 2.If not, Install pax from the source,bundled with the test. *Initialize:* 1.Create the directory structure,using the above script. *Test:* *1.Test 1: *Create a tar archive from the directory structure created,and list the contents of the created archive,and verify it with expected results. *2.Test 2:*List the contents of an archive, preferably one *that is not created* using pax, pax-source, for instance, that is already bundled with the test case. *3.Test 3:*Extract the archive created in Test 1 and examine the contents. *Cleanup* 1.Delete the created archives and directory structures -- *Regards, Rajeev S* *B Tech CSE Student* *Government Engineering College,Thrissur* *http://rajeevs.tk* *http://careers.stackoverflow.com/rajeevs* *https://github.com/rajeevs1992*
_______________________________________________ Autotest-kernel mailing list [email protected] https://www.redhat.com/mailman/listinfo/autotest-kernel
