view trunk/src/docgen/tests/doctemplate.d @ 451:3f44c38bf870

Page templates, more flexible writer interfaces, small fixes.
author Jari-Matti M?kel? <jmjm@iki.fi>
date Wed, 24 Oct 2007 17:25:52 +0300
parents 49f3afd6a0e8
children f658ec4a15dd
line wrap: on
line source

/**
 * Author: Jari-Matti Mäkelä
 * License: GPL3
 */
module docgen.tests.doctemplate;

import docgen.tests.common;
import docgen.document.writers;
import tango.io.Stdout;
import tango.io.FileConduit;
import tango.io.protocol.Writer : Writer;

// doc template
//@unittest
void doctemplate1() {
  auto gen = new TestDocGenerator;
  gen.options.docFormat = DocFormat.LaTeX;
  auto fname = "doctemplate.tex";
  
  auto gwf = new DefaultDocumentWriterFactory(gen);
  auto file = new FileConduit("docgen/teststuff/" ~ fname, FileConduit.WriteCreate);
  auto writer = gwf.createDocumentWriter( [ file ] );
  
  writer.generateDocument();
  
  file.close();
}