Package org.apache.hadoop.fs.shell.CopyCommands

Examples of org.apache.hadoop.fs.shell.CopyCommands.Cp


    assertAttributesChanged();
  }

  @Test(timeout = 10000)
  public void testCpWithP() throws Exception {
      run(new Cp(), "-p", FROM.toString(), TO.toString());
      assertAttributesPreserved();
  }
View Full Code Here


      assertAttributesPreserved();
  }

  @Test(timeout = 10000)
  public void testCpWithoutP() throws Exception {
      run(new Cp(), FROM.toString(), TO.toString());
      assertAttributesChanged();
  }
View Full Code Here

      assertAttributesChanged();
  }

  @Test(timeout = 10000)
  public void testDirectoryCpWithP() throws Exception {
    run(new Cp(), "-p", "d1", "d3");
    assertEquals(fs.getFileStatus(new Path("d1")).getModificationTime(),
        fs.getFileStatus(new Path("d3")).getModificationTime());
    assertEquals(fs.getFileStatus(new Path("d1")).getPermission(),
        fs.getFileStatus(new Path("d3")).getPermission());
  }
View Full Code Here

        fs.getFileStatus(new Path("d3")).getPermission());
  }

  @Test(timeout = 10000)
  public void testDirectoryCpWithoutP() throws Exception {
    run(new Cp(), "d1", "d4");
    assertTrue(fs.getFileStatus(new Path("d1")).getModificationTime() !=
        fs.getFileStatus(new Path("d4")).getModificationTime());
    assertTrue(!fs.getFileStatus(new Path("d1")).getPermission()
        .equals(fs.getFileStatus(new Path("d4")).getPermission()));
  }
View Full Code Here

    assertAttributesChanged();
  }

  @Test(timeout = 10000)
  public void testCpWithP() throws Exception {
      run(new Cp(), "-p", FROM.toString(), TO.toString());
      assertAttributesPreserved();
  }
View Full Code Here

      assertAttributesPreserved();
  }

  @Test(timeout = 10000)
  public void testCpWithoutP() throws Exception {
      run(new Cp(), FROM.toString(), TO.toString());
      assertAttributesChanged();
  }
View Full Code Here

TOP

Related Classes of org.apache.hadoop.fs.shell.CopyCommands.Cp

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.