-
Notifications
You must be signed in to change notification settings - Fork 2
/
test.js
60 lines (56 loc) · 1.43 KB
/
test.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
'use strict';
//const nanoTest = new (require('nanoTest')).test();
const fs = require('fs');
const _html_head_start = (
'<!DOCTYPE html>'+
'<html lang="en-US">'+
'<head>'+
'<meta charset="utf-8">'+
'<title>test page</title>'+
'<script>'
);
const _html_head_end = (
'</script>'+
'</head>'
);
const _html_body_start = (
'<body>'
);
const _html_body_end = (
'</body>'+
'</html>'
);
const _html_div_empty = '<div></div>';
const _html_div_text = '<div>div_with_text</div>';
const _html_div_class_empty = '<div class="class_empty"></div>';
const _html_div_class_text = '<div class="class_text">class_with_text</div>';
const _html_div_id_empty = '<div class="id_empty"></div>';
const _html_div_id_text = '<div class="id_text">id_with_text</div>';
const _trollhand_script = fs.readFileSync('index.js').toString();
const _trollhand_script_mini = fs.readFileSync('minify.js').toString();
const _html = (
_html_head_start+
_trollhand_script+
_html_head_end+
_html_body_start+
_html_div_empty+
_html_div_text+
_html_div_class_empty+
_html_div_class_text+
_html_div_id_empty+
_html_div_id_text+
_html_body_end
);
const _html_mini = (
_html_head_start+
_trollhand_script_mini+
_html_head_end+
_html_body_start+
_html_div_empty+
_html_div_text+
_html_div_class_empty+
_html_div_class_text+
_html_div_id_empty+
_html_div_id_text+
_html_body_end
);