コード例 #1
1
  public void testBasic() throws Exception {
    if (!Dpkg.available()) {
      return;
    }

    DebPackagingFormat packagingFormat = (DebPackagingFormat) lookup(PackagingFormat.ROLE, "deb");

    FileObject dpkgTest = VFS.getManager().resolveFile(getTestPath("target/deb-test"));
    FileObject packageRoot = dpkgTest.resolveFile("root");
    File packageFile = VfsUtil.asFile(dpkgTest.resolveFile("file.deb"));

    PackageVersion version = packageVersion("1.0", "123", false, some("1"));
    PackageParameters parameters =
        packageParameters(
                "mygroup",
                "myartifact",
                version,
                "id",
                "default-name",
                Option.<java.lang.String>none(),
                EMPTY,
                EMPTY)
            .contact("Kurt Cobain")
            .architecture("all");

    List<String> nil = List.nil();
    packagingFormat
        .start()
        .parameters(parameters)
        .debParameters(Option.<String>none(), some("devel"), false, nil, nil, nil, nil, nil, nil)
        .debug(true)
        .workingDirectory(packageRoot)
        .packageToFile(packageFile, ScriptUtil.Strategy.SINGLE);

    assertTrue(packageFile.canRead());
  }
コード例 #2
1
ファイル: RoseTree.java プロジェクト: MagnusSmith/javaslang
 @Override
 public List<NonNil<T>> getChildren() {
   return List.nil();
 }