Skip to content

Commit

Permalink
Add test case
Browse files Browse the repository at this point in the history
  • Loading branch information
sh4869 committed Jan 5, 2018
1 parent d954f58 commit 563584f
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions test/test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,18 @@ main() {
var response = await twitter.request("GET", "statuses/user_timeline.json");
expect(response.body,isNotNull);
});
// mulitple request test #5
test("mulitple request test",() async {
var envVars = Platform.environment;
Map keyMap = {
"consumerKey": envVars['CONSUMER_KEY'],
"consumerSecret": envVars['CONSUMER_SECRET'],
"accessToken": envVars['ACCESS_TOKEN'],
"accessSecret": envVars['ACCESS_TOKEN_SECRET']
};
var twitter = new Twitter.fromMap(keyMap);
var response = await twitter.request("GET", "statuses/user_timeline.json");
var response2 = await twitter.request("GET", "statuses/user_timeline.json");
expect(response.body, isNotNull);
});
}

0 comments on commit 563584f

Please sign in to comment.