for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
from bears.js.JSONFormatBear import JSONFormatBear
from bears.tests.LocalBearTestHelper import verify_local_bear
test_file1 = """{
"a": 5,
"b": 5
}""".split("\n")
test_file2 = """{
"b": 5,
"a": 5
test_file3 = """{
JSONFormatBear1Test = verify_local_bear(JSONFormatBear,
valid_files=(test_file1, test_file2),
invalid_files=(test_file3,
[""],
["random stuff"],
['{"a":5,"b":5}']))
JSONFormatBear2Test = verify_local_bear(JSONFormatBear,
valid_files=(test_file1,),
invalid_files=(test_file2,),
settings={"json_sort": "true"})
JSONFormatBear3Test = verify_local_bear(JSONFormatBear,
valid_files=(test_file3,),
invalid_files=(test_file2),
settings={"tab_width": "3"})