Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed-rtos mbed HTTPClient VodafoneUSBModem
Tests/Test08.cpp@45:f68fea0831d7, 2012-09-18 (annotated)
- Committer:
- ashleymills
- Date:
- Tue Sep 18 15:38:54 2012 +0000
- Revision:
- 45:f68fea0831d7
- Child:
- 46:d2c22206031a
Framework now prints out description of failed tests. Put in placeholders for all test descriptions. Started working on Test08.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
ashleymills | 45:f68fea0831d7 | 1 | #include "Test08.h" |
ashleymills | 45:f68fea0831d7 | 2 | |
ashleymills | 45:f68fea0831d7 | 3 | Test08::Test08(VodafoneUSBModem *m) : VodafoneTestCase(m) { |
ashleymills | 45:f68fea0831d7 | 4 | _description = gTest08Description; |
ashleymills | 45:f68fea0831d7 | 5 | _testCaseNumber = 8; |
ashleymills | 45:f68fea0831d7 | 6 | } |
ashleymills | 45:f68fea0831d7 | 7 | |
ashleymills | 45:f68fea0831d7 | 8 | void Test08::setupTest() {} |
ashleymills | 45:f68fea0831d7 | 9 | |
ashleymills | 45:f68fea0831d7 | 10 | bool Test08::executeTest() { |
ashleymills | 45:f68fea0831d7 | 11 | bool outcome = true; |
ashleymills | 45:f68fea0831d7 | 12 | LOG("Description: %s",gTest08Description); |
ashleymills | 45:f68fea0831d7 | 13 | LOG("Connecting to internet"); |
ashleymills | 45:f68fea0831d7 | 14 | if(_modem->connect("internet","web","web")==0) { |
ashleymills | 45:f68fea0831d7 | 15 | LOG("Connected to internet"); |
ashleymills | 45:f68fea0831d7 | 16 | } else { |
ashleymills | 45:f68fea0831d7 | 17 | LOG("Failed to connect to internet"); |
ashleymills | 45:f68fea0831d7 | 18 | outcome = false; |
ashleymills | 45:f68fea0831d7 | 19 | } |
ashleymills | 45:f68fea0831d7 | 20 | |
ashleymills | 45:f68fea0831d7 | 21 | LOG("Doing DNS lookup for X"); |
ashleymills | 45:f68fea0831d7 | 22 | |
ashleymills | 45:f68fea0831d7 | 23 | _modem->disconnect(); |
ashleymills | 45:f68fea0831d7 | 24 | return outcome; |
ashleymills | 45:f68fea0831d7 | 25 | } |
ashleymills | 45:f68fea0831d7 | 26 | |
ashleymills | 45:f68fea0831d7 | 27 | void Test08::endTest() { } |