summaryrefslogtreecommitdiff
path: root/js/test.js
diff options
context:
space:
mode:
authorArthur <arthur.peka@outlook.com>2014-09-26 01:01:02 +0300
committerArthur <arthur.peka@outlook.com>2014-09-26 01:01:02 +0300
commit72a381b2a00f3832d8d74dbc9a5faa88fda0450a (patch)
treeed8729a4354d1ec2dcf3354e99ff431da84d8d57 /js/test.js
parentc006aececef112f61dd44cad43f0596221f29700 (diff)
Changing some variable names to more explicit ones to improve readability
Diffstat (limited to 'js/test.js')
-rwxr-xr-xjs/test.js10
1 files changed, 5 insertions, 5 deletions
diff --git a/js/test.js b/js/test.js
index 19c0c92..033ab32 100755
--- a/js/test.js
+++ b/js/test.js
@@ -30,13 +30,13 @@ fs.readFile('spec.txt', 'utf8', function(err, data) {
.replace(/^<!-- END TESTS -->(.|[\n])*/m, '');
tests.replace(/^\.\n([\s\S]*?)^\.\n([\s\S]*?)^\.$|^#{1,6} *(.*)$/gm,
- function(_,x,y,z){
- if (z) {
- current_section = z;
+ function(_,firstSubmatch,secondSubmatch,thirdSubmatch){
+ if (thirdSubmatch) {
+ current_section = thirdSubmatch;
} else {
example_number++;
- examples.push({markdown: x,
- html: y,
+ examples.push({markdown: firstSubmatch,
+ html: secondSubmatch,
section: current_section,
number: example_number});
}