Repository: hadoop Updated Branches: refs/heads/branch-2.8 a29130651 -> ee28034a8
HDFS-10814. Add assertion for getNumEncryptionZones when no EZ is created. Contributed by Vinitha Reddy Gankidi. (cherry picked from commit 4bd45f54eedd449a98a90540698c6ceb47454fec) Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/ee28034a Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/ee28034a Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/ee28034a Branch: refs/heads/branch-2.8 Commit: ee28034a8a155406b111813602cb5f4fb3fb1f4d Parents: a291306 Author: Zhe Zhang <[email protected]> Authored: Mon Aug 29 23:37:26 2016 -0700 Committer: Zhe Zhang <[email protected]> Committed: Mon Aug 29 23:43:04 2016 -0700 ---------------------------------------------------------------------- .../test/java/org/apache/hadoop/hdfs/TestEncryptionZones.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee28034a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestEncryptionZones.java ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestEncryptionZones.java b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestEncryptionZones.java index 0ebe05c..6ae2aca 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestEncryptionZones.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestEncryptionZones.java @@ -326,7 +326,9 @@ public class TestEncryptionZones { public void testBasicOperations() throws Exception { int numZones = 0; - + /* Number of EZs should be 0 if no EZ is created */ + assertEquals("Unexpected number of encryption zones!", numZones, + cluster.getNamesystem().getNumEncryptionZones()); /* Test failure of create EZ on a directory that doesn't exist. */ final Path zoneParent = new Path("/zones"); final Path zone1 = new Path(zoneParent, "zone1"); --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
