Bug 1391952 - Introduce camel case lint rule. r?automatedtester draft
authorAndreas Tolfsen <ato@sny.no>
Sat, 19 Aug 2017 14:18:51 +0100
changeset 649879 ccce76ac5c6a5c90deb8eb46df70fe0f392d0fb9
parent 649878 8c22bf93cc03a8f8047cc6b5b1a1891c253c02ee
child 727219 b9d6f67c148e84723fc26bf9d10ddb8146957f98
push id75183
push userbmo:ato@sny.no
push dateMon, 21 Aug 2017 12:43:49 +0000
reviewersautomatedtester
bugs1391952
milestone57.0a1
Bug 1391952 - Introduce camel case lint rule. r?automatedtester The Firefox remote protocol in testing/marionette predominantly uses camel casing in naming properties and variables. To enforce consistency with this practice, this patch adds an eslint rule to enforce camel case. There are a few exceptions where we use snake case in response output. We can disable the lint rule on an individual basis in this handful of cases. MozReview-Commit-ID: DL7msdriFil
testing/marionette/.eslintrc.js
--- a/testing/marionette/.eslintrc.js
+++ b/testing/marionette/.eslintrc.js
@@ -1,12 +1,13 @@
 "use strict";
 
 module.exports = {
   "rules": {
+    "camelcase": "error",
     "comma-dangle": ["error", "always-multiline"],
     "indent": ["error", 2, {
       "CallExpression": {"arguments": 2},
       "FunctionExpression": {"body": 1, "parameters": 2},
       "MemberExpression": 2,
       "SwitchCase": 1,
     }],
     "max-len": ["error", 78, {