{"size": 1152, "ext": "js", "max_stars_repo_path": "test/test.js", "max_stars_repo_name": "Rycochet/postcss-epub", "max_stars_repo_stars_event_min_datetime": "2015-01-23T17:38:48.000Z", "max_stars_repo_stars_event_max_datetime": "2021-12-22T17:12:59.000Z", "max_issues_repo_path": "test/test.js", "max_issues_repo_name": "Rycochet/postcss-epub", "max_issues_repo_issues_event_min_datetime": "2015-05-23T13:03:43.000Z", "max_issues_repo_issues_event_max_datetime": "2016-11-29T13:51:31.000Z", "max_forks_repo_path": "test/test.js", "max_forks_repo_name": "Rycochet/postcss-epub", "max_forks_repo_forks_event_min_datetime": "2015-02-13T08:38:04.000Z", "max_forks_repo_forks_event_max_datetime": "2019-01-31T20:48:15.000Z"}
{"max_stars_count": 25, "max_issues_count": 4, "max_forks_count": 6, "avg_line_length": 33.8823529412, "max_line_length": 104, "alphanum_fraction": 0.6779513889}
var assert = require("assert"),
		epub = require(".."),
		read = require("fs").readFileSync,
		postcss = require("postcss");

function readFile(name) {
	return read("test/" + name + ".css", "utf8").trim();
}

function processFile(name) {
	return postcss()
			.use(epub({strict:true}))
			.process(readFile(name))
			.css
			.trim();
}

exports["test epub css \"text\" output gets correct prefixes"] = function() {
	assert.equal(processFile("epub-text"), readFile("epub-text.out"), "CSS Text not as expected");
};
exports["test epub css \"writing\" output gets correct prefixes"] = function() {
	assert.equal(processFile("epub-writing"), readFile("epub-writing.out"), "CSS Writing not as expected");
};
exports["test epub css \"speech\" output gets correct prefixes"] = function() {
	assert.equal(processFile("epub-speech"), readFile("epub-speech.out"), "CSS Speech not as expected");
};
exports["test epub css \"@font-face\" output gets correct properties and types"] = function() {
	assert.equal(processFile("epub-font"), readFile("epub-font.out"), "CSS Font-Face not as expected");
};

if (module === require.main) {
	require("test").run(exports);
}
