Skip to content

Commit 8d38f25

Browse files
committed
Change layouts export to access list from layouts.all
1 parent 262faed commit 8d38f25

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

index.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ const gatherFiles = require('./scripts/gather-files');
33
const iconSvgPath = path.join(__dirname, './icons');
44

55
module.exports = {
6-
layouts: {
7-
all: require('./layouts/all.json')
8-
},
6+
layouts: require('./layouts/all.json'),
97
svgArray: gatherFiles(iconSvgPath)
108
};

test/maki.test.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,17 @@ const fs = require('fs');
22
const test = require('tape');
33
const path = require('path');
44
const xml2js = require('xml2js');
5+
const maki = require('../');
56
const makiLayoutAll = require('../layouts/all');
67

78
const parseString = xml2js.parseString;
89
const svgPath = path.join(__dirname, '../icons/');
910

11+
test('index', function(t) {
12+
t.deepEqual(makiLayoutAll.all, maki.layouts.all, 'exports layout.all');
13+
t.end();
14+
});
15+
1016
test('all.json layout ', function(t) {
1117
fs.readdir(svgPath, function(err, files) {
1218
var svgFiles = files.filter(function(file) {

0 commit comments

Comments
 (0)