Skip to content

Conversation

@adoroszlai
Copy link
Contributor

@adoroszlai adoroszlai commented Jun 18, 2020

What changes were proposed in this pull request?

  1. Split monolithic Ozone FS acceptance test case into several steps. This improves feedback about test progress, and makes easier to find out what's wrong in case of a failure. (Unfortunately most subsequent steps still depend on earlier ones. Improving that would be nice, but would make the test slower due to the necessary extra setup steps.)
  2. Run test setup in proper Setup instead of a test case.
  3. Split test setup into reusable keywords.
  4. Add functions for formatting Ozone FS URLs with both o3fs and ofs flavor. Includes its own test cases.
  5. Test execution for ofs and o3fs is controlled outside of the test script. This is necessary to avoid duplication of test cases and/or keywords.
  6. Pass SECURITY_ENABLED and similar variables as Robot variables (-v), not environment ones (-e). This allows setting default value in Robot tests, which makes it easier to run the test from command-line.

Most of this is in preparation for bucket links, as the same test should be executed for regular buckets and links. Submitting as a separate PR for easier review.

Note that this PR is based on top of the change for #1091, a minor improvement which is necessary to save output of multiple executions of the same test suite (ozonefs.robot in this case).

https://issues.apache.org/jira/browse/HDDS-3826

How was this patch tested?

Ran tests for lib locally (no docker-compose):

$ robot lib
...
Lib.Fs Tests                                                          | PASS |
...
Lib.String Tests                                                      | PASS |
...

Ran Ozone FS tests inside docker container bypassing test.sh:

$ docker-compose exec scm robot smoketest/ozonefs/ozonefs.robot
...
Ozonefs :: Ozone FS tests                                             | PASS |
20 critical tests, 20 passed, 0 failed

$ docker-compose exec scm robot -v SCHEME:o3fs smoketest/ozonefs/ozonefs.robot
...
Ozonefs :: Ozone FS tests                                             | PASS |
20 critical tests, 20 passed, 0 failed

Full acceptance test suite:
https://github.com/adoroszlai/hadoop-ozone/runs/783679213
https://github.com/adoroszlai/hadoop-ozone/runs/784247369

@adoroszlai adoroszlai self-assigned this Jun 18, 2020
@adoroszlai adoroszlai requested review from elek and smengcl June 18, 2020 13:49
@elek
Copy link
Member

elek commented Jun 22, 2020

Pass SECURITY_ENABLED and similar variables as Robot variables (-v), not environment ones (-e). This allows setting default value in Robot tests, which makes it easier to run the test from command-line.

DANCING BANANA. Thank you very much,

The patch LGTM.

One comment: string_test.robot and fs_test.robot seems to be duplicate of robot.robot. (I guess you refactored the robot.robot to two separated files.) I think one of them can be removed.

@adoroszlai
Copy link
Contributor Author

One comment: string_test.robot and fs_test.robot seems to be duplicate of robot.robot. I think one of them can be removed.

Nice catch.

(I guess you refactored the robot.robot to two separated files.)

Exactly.

Copy link
Member

@elek elek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks the update (and the patch): merging to the master.

@elek elek merged commit 755170d into apache:master Jun 22, 2020
@adoroszlai adoroszlai deleted the HDDS-3826 branch June 22, 2020 13:54
@adoroszlai
Copy link
Contributor Author

Thanks @elek for reviewing and committing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants