Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/parsers/config_parser_json.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
library config_parser_json;

import 'dart:async';
import 'dart:json' as JSON;
import 'dart:convert';

import '../config.dart';

Expand All @@ -10,7 +10,7 @@ class JsonConfigParser implements ConfigParser {
Future<Map> parse(String configText) {
var completer = new Completer<Map>();

var map = JSON.parse(configText);
var map = JSON.decode(configText);
completer.complete(map);

return completer.future;
Expand Down
4 changes: 2 additions & 2 deletions test/tests.dart
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ class MapMatcher implements Matcher {

// JSON parse the item back into a map, and compare the two maps
// (brute force, innefficient)
bool matches(Map item, MatchState matchState) {
bool matches(Map item, Map matchState) {
var result = true;

// try and compare the item and the map
Expand All @@ -120,7 +120,7 @@ class MapMatcher implements Matcher {
}

Description describeMismatch(item, Description mismatchDescription,
MatchState matchState, bool verbose) {
Map matchState, bool verbose) {
mismatchDescription.add("item: ${item.toString()}");
return mismatchDescription;

Expand Down