Commit Graph

18 Commits

Author SHA1 Message Date
Rishabh Dave
54562691ee test_cephfs_shell: test du with multiple paths in args
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:45:34 +05:30
Rishabh Dave
08c7e2862b test_cephfs_shell: test behaviour of "du -r"
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:45:31 +05:30
Rishabh Dave
7f7aed5506 test_cephfs_shell: test du's output for softlinks
Test that CephFS shell command du prints output for softlinks as
expected

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:45:27 +05:30
Rishabh Dave
877a79d8cf test_cephfs_shell: test du's output for hardlinks
Test that CephFS shell command du prints output for directories as
expected.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:45:11 +05:30
Rishabh Dave
7062dd6164 test_cephfs_shell: test du's output for directories
Test that CephFS shell command du prints output for directories as
expected.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:45:08 +05:30
Rishabh Dave
370c97678d test_cephfs_shell: test du's output for regular files
Test that CephFS shell command du prints an output for regular files
correctly.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:45:04 +05:30
Rishabh Dave
d3f895f44a test_cephfs_shell: add a method to get command output
Let run_cephfs_shell_cmd() return the object instead of output in string
format so that stderr, return value, etc. of the command executed
remain available. And add a new method that returns only output of the
CephFS shell command executed.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:44:59 +05:30
Rishabh Dave
f0723d200c test_cephfs_shell: allow cmd as list too
Convert cmd to string if it is passed as list to
run_cephfs_shell_cmd(). Allowing cmd to be list would be nice since
elsewhere, in tests, command to be executed must be a list of arguments
rather than string of arguments separated by spaces.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:44:39 +05:30
Rishabh Dave
e6f3bf8ccd test_cephfs_shell: rename and rewrite _cephfs_shell()
Rename _cephfs_shell() to run_cephfs_shell_cmd() and add a default
client for run_cephfs_shell_cmd() since most of tests in this
testsuite will need only one client.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:44:35 +05:30
Rishabh Dave
e5f30052f9 test_cephfs_shell: copy humanize() from cephfs-shell
Copy the method named humanize from cephfs-shell so that output can be
compared. Unfortunately, importing this method isn't possible since the
dash in "cephfs-shell" leads to an syntax error.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-09-13 10:43:55 +05:30
Rishabh Dave
d94a42dc1b test_cephfs_shell: add a test for cd with arguments
Add a method to test that the cd command changes the current working
directory to the path passed as an argument to it.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-07-25 10:51:50 +05:30
Rishabh Dave
dee9ec1650 test_cephfs_shell: add a test for cd with no arguments
Add a method to test that the cd command changes the current working
directory to root when no argument is passed.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-07-25 10:51:50 +05:30
Rishabh Dave
70f22f69b5 test_cephfs_shell: group test methods
Move tests into different classes created on the basis of a shell
functionality within the testsuite. This arrangement allows running
tests related to only one functionality at a time.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-07-25 10:51:50 +05:30
Rishabh Dave
2a98e9cb31 test_cephfs_shell: add a new method to return script output
Add a new method that runs the given CephFS shell script on the given
mount and returns the output with whitespace removed.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-07-25 10:51:28 +05:30
Rishabh Dave
fef0180c93 test_cephfs_shell: allow running CephFS shell script
Add a method to test_cephfs_shell.py that allows running CephFS shell
script using option "-b" of cephfs-shell.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-07-25 10:51:11 +05:30
Patrick Donnelly
ff1f04f4d5
qa: elide python version config
This test doesn't actually use the config and cephfs-shell is py3 only.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2019-06-19 18:22:51 -07:00
Milind Changire
73ada8d1d9 cephfs-shell: teuthology tests
* mkdir
* get
* put

Fixes: http://tracker.ceph.com/issues/39526
Signed-off-by: Milind Changire <mchangir@redhat.com>
2019-05-09 11:37:31 +05:30
Patrick Donnelly
0b5df6e00a
qa: add cephfs-shell skeleton test case
Right now just tests that "help" works.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2018-08-16 09:13:36 -07:00