Skip to content

Commit b7dd991

Browse files
committed
Fixed test annotations
1 parent 72513b9 commit b7dd991

File tree

8 files changed

+12
-35
lines changed

8 files changed

+12
-35
lines changed

README.md

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
a Client (VM, Flutter, Web), and a Server (VM only).
44

55

6-
## Client
6+
## Supported features
77
- [x] Fetching single resources and resource collections
88
- [x] Collection pagination
99
- [x] Fetching relationships and related resources and collections
@@ -17,23 +17,6 @@ a Client (VM, Flutter, Web), and a Server (VM only).
1717
- [x] Related collection pagination
1818
- [x] Asynchronous processing
1919

20-
#### Server
21-
- [x] Fetching single resources and resource collections
22-
- [x] Collection pagination
23-
- [x] Fetching relationships and related resources and collections
24-
- [x] Fetching single resources
25-
- [x] Creating resources
26-
- [x] Deleting resources
27-
- [x] Updating resource's attributes
28-
- [x] Updating resource's relationships
29-
- [x] Updating relationships
30-
- [x] Related collection pagination
31-
- [x] Compound documents
32-
- [x] Asynchronous processing
33-
34-
#### Document
35-
- [x] Support relationship objects lacking the `data` member
36-
- [x] Compound documents
3720
- [ ] Support `meta` members
3821
- [ ] Support `jsonapi` members
3922
- [ ] Structural Validation including compound documents and sparse fieldsets

test/browser_compat_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@ void main() async {
1414
expect(r.status, 200);
1515
expect(r.isSuccessful, true);
1616
expect(r.data.collection.first.attributes['name'], 'Tesla');
17-
});
17+
}, testOn: 'browser');
1818
}

test/functional/create_test.dart

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import 'dart:async';
2-
@TestOn('vm')
32
import 'dart:io';
43

54
import 'package:json_api/client.dart';
@@ -128,5 +127,5 @@ void main() async {
128127
expect(r0.isSuccessful, false);
129128
expect(r0.document.errors.first.detail, 'Incompatible type');
130129
});
131-
});
130+
}, testOn: 'vm');
132131
}

test/functional/delete_test.dart

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
@TestOn('vm')
21
import 'dart:io';
32

43
import 'package:json_api/client.dart';
@@ -56,5 +55,5 @@ void main() async {
5655
final r0 = await client.fetchResource(Url.resource('models', '555'));
5756
expect(r0.status, 404);
5857
});
59-
});
58+
}, testOn: 'vm');
6059
}

test/functional/fetch_test.dart

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
@TestOn('vm')
21
import 'dart:io';
32

43
import 'package:json_api/client.dart';
@@ -100,7 +99,7 @@ void main() async {
10099
expect(r.isSuccessful, false);
101100
expect(r.document.errors.first.detail, 'Unknown resource type');
102101
});
103-
});
102+
}, testOn: 'vm');
104103

105104
group('single resource', () {
106105
test('single resource', () async {
@@ -137,7 +136,7 @@ void main() async {
137136
expect(r.status, 404);
138137
expect(r.isSuccessful, false);
139138
});
140-
});
139+
}, testOn: 'vm');
141140

142141
group('related resource', () {
143142
test('related resource', () async {
@@ -167,7 +166,7 @@ void main() async {
167166
expect(r.status, 404);
168167
expect(r.isSuccessful, false);
169168
});
170-
});
169+
}, testOn: 'vm');
171170

172171
group('relationships', () {
173172
test('to-one', () async {
@@ -237,5 +236,5 @@ void main() async {
237236
expect(r.data.related.uri.toString(),
238237
'http://localhost:8080/companies/1/models');
239238
});
240-
});
239+
}, testOn: 'vm');
241240
}

test/functional/update_test.dart

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
@TestOn('vm')
21
import 'dart:io';
32

43
import 'package:json_api/client.dart';
@@ -126,7 +125,7 @@ void main() async {
126125
expect(r1.status, 409);
127126
expect(r1.document.errors.first.detail, 'Incompatible type');
128127
});
129-
});
128+
}, testOn: 'vm');
130129

131130
/// Updating Relationships
132131
/// ======================
@@ -191,7 +190,7 @@ void main() async {
191190
expect(r2.document.data.toIdentifier(), isNull);
192191
});
193192
});
194-
});
193+
}, testOn: 'vm');
195194

196195
/// Updating To-Many Relationships
197196
/// ==============================
@@ -255,5 +254,5 @@ void main() async {
255254
});
256255
});
257256
});
258-
});
257+
}, testOn: 'vm');
259258
}

test/unit/document_test.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
@TestOn('vm')
21
import 'package:json_api/document.dart';
32
import 'package:json_matcher/json_matcher.dart';
43
import 'package:test/test.dart';

test/unit/parser_test.dart

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
@TestOn('vm')
21
import 'dart:convert';
32
import 'dart:io';
43

@@ -24,5 +23,5 @@ void main() {
2423
} catch (e, s) {
2524
print(s);
2625
}
27-
});
26+
}, testOn: 'vm');
2827
}

0 commit comments

Comments
 (0)