Skip to content

Commit

Permalink
Merge pull request mapbox#264 from mapbox/farm
Browse files Browse the repository at this point in the history
Farm
  • Loading branch information
samanpwbb committed May 5, 2016
2 parents 37521c2 + aca2d2c commit 1d0efbb
Show file tree
Hide file tree
Showing 9 changed files with 176 additions and 52 deletions.
2 changes: 1 addition & 1 deletion icons/aerialway-11.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
65 changes: 48 additions & 17 deletions icons/dog-park-15.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions icons/farm-11.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions icons/farm-15.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
62 changes: 47 additions & 15 deletions icons/grocery-15.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
63 changes: 48 additions & 15 deletions icons/rail-15.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion layouts/all.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"all":["aerialway","airfield","airport","alcohol-shop","america-football","amusement-park","aquarium","art-gallery","attraction","bakery","bank","bar","baseball","basketball","beer","bicycle","bicycle-share","building","bus","cafe","campsite","car","castle","cemetery","cinema","circle","circle-stroked","clothing-store","college","commercial","cricket","cross","dam","danger","dentist","doctor","dog-park","drinking-water","embassy","entrance","fast-food","ferry","fire-station","fuel","garden","gift","golf","grocery","hairdresser","harbor","heart","heliport","hospital","ice-cream","industry","information","laundry","library","lighthouse","lodging","marker","monument","mountain","museum","music","park","parking","parking-garage","pharmacy","picnic-site","pitch","place-of-worship","playground","police","post","prison","rail","rail-light","rail-metro","ranger-station","religious-christian","religious-jewish","religious-muslim","restaurant","roadblock","rocket","school","shelter","shop","skiing","soccer","square","square-stroke","stadium","star","star-stroke","suitcase","sushi","swimming","telephone","tennis","theatre","toilet","town-hall","triangle","triangle-stroked","veterinary","volcano","warehouse","waste-basket","water","wetland","wheelchair","zoo"]}
{"all":["aerialway","airfield","airport","alcohol-shop","america-football","amusement-park","aquarium","art-gallery","attraction","bakery","bank","bar","baseball","basketball","beer","bicycle","bicycle-share","building","bus","cafe","campsite","car","castle","cemetery","cinema","circle","circle-stroked","clothing-store","college","commercial","cricket","cross","dam","danger","dentist","doctor","dog-park","drinking-water","embassy","entrance","farm","fast-food","ferry","fire-station","fuel","garden","gift","golf","grocery","hairdresser","harbor","heart","heliport","hospital","ice-cream","industry","information","laundry","library","lighthouse","lodging","marker","monument","mountain","museum","music","park","parking","parking-garage","pharmacy","picnic-site","pitch","place-of-worship","playground","police","post","prison","rail","rail-light","rail-metro","ranger-station","religious-christian","religious-jewish","religious-muslim","restaurant","roadblock","rocket","school","shelter","shop","skiing","soccer","square","square-stroke","stadium","star","star-stroke","suitcase","sushi","swimming","telephone","tennis","theatre","toilet","town-hall","triangle","triangle-stroked","veterinary","volcano","warehouse","waste-basket","water","wetland","wheelchair","zoo"]}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"author": "Mapbox",
"name": "maki",
"description": "Pixel-perfect icons for web cartography",
"version": "2.0.2",
"version": "2.0.4",
"main": "index.js",
"scripts": {
"test": "tape test/maki.test.js | tap-spec",
Expand Down
23 changes: 21 additions & 2 deletions test/maki.test.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,30 @@
var fs = require('fs'),
path = require('path'),
test = require('tape'),
xml2js = require('xml2js');
xml2js = require('xml2js'),
makiLayoutAll = require('../layouts/all');

var parseString = xml2js.parseString;

test('valid svgs', function(t) {
test('all.json layout ', function(t) {
fs.readdir('./icons/', function(err, files) {
var svgFiles = files.filter(function(file) {
return file.split('.').pop().indexOf('svg') !== -1;
});
var filtered = svgFiles
.filter(function(file) {
return file.indexOf('-11.svg') > -1;
})
.map(function(file) {
return file.split('-11.svg')[0];
});
t.deepEqual(filtered, makiLayoutAll.all, 'includes all icons');
t.end();
});

});

test('valid svgs ', function(t) {

fs.readdir('./icons/', function(err, files) {
var svgFiles = files.filter(function(file) {
Expand Down

0 comments on commit 1d0efbb

Please sign in to comment.