smengcl commented on code in PR #4538:
URL: https://github.com/apache/ozone/pull/4538#discussion_r1203213600
##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/ozone/shell/TestOzoneTenantShell.java:
##########
@@ -496,12 +496,10 @@ public void testOzoneTenantBasicOperations() throws
IOException {
checkOutput(err, "Assigned 'bob' to 'finance' with accessId"
+ " 'finance$bob'.\n", true);
- // Try user getsecret again after assignment, should succeed
+ // Try user getsecret again after assignment, should fail
executeHA(tenantShell, new String[] {
"user", "getsecret", "finance$bob"});
- checkOutput(out, "export AWS_ACCESS_KEY_ID='finance$bob'\n",
- false);
- checkOutput(err, "", true);
+ checkOutput(err, "Secret for 'finance$bob' already exists\n", true);
Review Comment:
```suggestion
checkOutput(out, "", true);
checkOutput(err, "Secret for 'finance$bob' already exists\n", true);
```
##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/ozone/shell/TestOzoneTenantShell.java:
##########
@@ -496,12 +496,10 @@ public void testOzoneTenantBasicOperations() throws
IOException {
checkOutput(err, "Assigned 'bob' to 'finance' with accessId"
+ " 'finance$bob'.\n", true);
- // Try user getsecret again after assignment, should succeed
+ // Try user getsecret again after assignment, should fail
executeHA(tenantShell, new String[] {
"user", "getsecret", "finance$bob"});
- checkOutput(out, "export AWS_ACCESS_KEY_ID='finance$bob'\n",
- false);
- checkOutput(err, "", true);
+ checkOutput(err, "Secret for 'finance$bob' already exists\n", true);
Review Comment:
Check stdout emptiness.
```suggestion
checkOutput(out, "", true);
checkOutput(err, "Secret for 'finance$bob' already exists\n", true);
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]