Skip to content

Commit

Permalink
Validate markets data.
Browse files Browse the repository at this point in the history
+ Resolves #44.
  • Loading branch information
johnjohndoe committed Jul 4, 2016
1 parent e689d5c commit fcba3aa
Show file tree
Hide file tree
Showing 4 changed files with 624 additions and 2 deletions.
10 changes: 10 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,16 @@ $ git push --force origin feature
* You might wanna use **German spelling** with Umlauts for city names which is supported.
* Add your city to the list of **supported cities** in the *README.md*.

### Market data validation

* The GeoJSON file will automatically be checked by a validation script when you push your
branch to the server. Please resolve any issues detected by the validator.
* The validation script can be executed locally with the following command:

``` bash
$ npm test
```


## Code contributions

Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ A small visualization of the weekly markets in different cities. Available at: h
These information are being used to set the initial position of the map. They must be part of
the city-specific GeoJSON file. Please adapt the format as being used in *cities/karlsruhe.json*.
* Further, the **data source** must be specified so it can be shown in the legend overlay.
* A validation script will automatically be executed to ensure required attributes are present in
the GeoJSON file.
* Finally add your city to the *cities/cities.json* file.


Expand Down
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@
"name": "wo-ist-markt",
"version": "0.0.1",
"devDependencies": {
"colors": "~1.1.2",
"jasmine": "^2.4.1",
"jshint": "~2.9.1",
"moment": "~2.11.0",
"opening_hours": "~3.4.0"
},
"scripts": {
"lint": "jshint js preprocessing",
"lint": "jshint js preprocessing validation",
"jasmine-tests": "jasmine",
"test": "npm run lint & npm run jasmine-tests"
"test": "npm run lint & npm run jasmine-tests & npm run validate",
"validate": "node validation/markets-validator.js"
}
}
Loading

0 comments on commit fcba3aa

Please sign in to comment.