forked from FangLiu68/VisitMe
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1. Add dbunit jars and a test data xml.
2. Change the JSONObject.append() to put(), because append() inserts a JSONArray instead of a JSONObject. 3. Add a param to DBConnect's constructor, add close() and unsetVisitedRestaurants() to make it testable.
- Loading branch information
Showing
13 changed files
with
87 additions
and
36 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<?xml version='1.0' encoding='UTF-8'?> | ||
<dataset> | ||
<restaurants business_id="--5jkZ3-nUPZxUvtcbr8Uw" name="Mika's Greek" categories="Greek,Mediterranean,Restaurants" city="Scottsdale" state="AZ" stars="4.5" full_address="1336 N Scottsdale Rd
Scottsdale, AZ 85257" latitude="33.4634" longitude="-111.927" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="--BlvDO_RG2yElKu9XA1_g" name="Asian Island" categories="Sushi Bars,Hawaiian,Chinese,Restaurants" city="Scottsdale" state="AZ" stars="4.0" full_address="14870 N Northsight Blvd
Ste 103
Scottsdale, AZ 85260" latitude="33.6212" longitude="-111.898" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="--jFTZmywe7StuZ2hEjxyA" name="Subway" categories="Fast Food,Sandwiches,Restaurants" city="Las Vegas" state="NV" stars="3.5" full_address="3991 Dean Martin Dr
Las Vegas, NV 89103" latitude="36.1188" longitude="-115.182" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="--pOlFxITWnhzc7SHSIP0A" name="Block & Grinder" categories="American (New),Restaurants" city="Charlotte" state="NC" stars="4.0" full_address="2935 Providence Rd
Sherwood Forest
Charlotte, NC 28211" latitude="35.1711" longitude="-80.8071" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="--qeSYxyn62mMjWvznNTdg" name="Panda Express" categories="Chinese,Restaurants" city="Casa Grande" state="AZ" stars="4.0" full_address="1747 E Florence Blvd
Casa Grande, AZ 85122" latitude="32.8792" longitude="-111.712" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="--UE_y6auTgq3FXlvUMkbw" name="Ritters Diner" categories="Diners,Restaurants" city="Pittsburgh" state="PA" stars="3.5" full_address="5221 Baum Blvd
Bloomfield
Pittsburgh, PA 15224" latitude="40.4564" longitude="-79.9413" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="--Y_2lDOtVDioX5bwF6GIw" name="Buck & Badger" categories="Bars,Comfort Food,Nightlife,Restaurants" city="Madison" state="WI" stars="3.0" full_address="115 State St
Capitol
Madison, WI 53703" latitude="43.0747" longitude="-89.3871" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="--zgHBiQpr8H2ZqSdGmguQ" name="China Star Buffet" categories="Buffets,Chinese,Restaurants" city="Las Vegas" state="NV" stars="3.0" full_address="3743 South Las Vegas Bl
The Strip
Las Vegas, NV 89109" latitude="36.1065" longitude="-115.172" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-024YEtnIsPQCrMSHCKLQw" name="Presse Cafe" categories="Cafes,Restaurants" city="Montréal" state="QC" stars="3.5" full_address="1750 Saint-Denis Rue
Montréal, QC H2X 3K6" latitude="45.5157" longitude="-73.5651" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-0bl9EllYlei__4dl1W00Q" name="Wee Bite" categories="Breakfast & Brunch,Restaurants" city="Edinburgh" state="EDH" stars="3.5" full_address="Saint Mary's Street
Newington
Edinburgh EH8 8" latitude="55.9496" longitude="-3.18347" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-0bUDim5OGuv8R0Qqq6J4A" name="IHOP" categories="Bakeries,Food,Breakfast & Brunch,Restaurants" city="Phoenix" state="AZ" stars="2.0" full_address="7023 N 19th Ave
Phoenix, AZ 85021" latitude="33.5397" longitude="-112.099" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-0GkcDiIgVm0XzDZC8RFOg" name="Crane Alley" categories="Bars,American (Traditional),Nightlife,Restaurants" city="Urbana" state="IL" stars="3.5" full_address="115 W Main St
Urbana, IL 61801" latitude="40.1122" longitude="-88.208" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-0HGqwlfw3I8nkJyMHxAsQ" name="McDonald's" categories="Burgers,Fast Food,Restaurants" city="Phoenix" state="AZ" stars="4.0" full_address="4750 E Warner Rd
Phoenix, AZ 85044" latitude="33.3312" longitude="-111.981" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-0lOuL7RkZQnjAl96dXTvA" name="New York Pizza Dept" categories="Pizza,Restaurants" city="Gilbert" state="AZ" stars="3.5" full_address="2743 S Market St
Gilbert, AZ 85295" latitude="33.3008" longitude="-111.743" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-0QBrNvhrPQCaeo7mTo0zQ" name="La Salcita" categories="Restaurants" city="Phoenix" state="AZ" stars="4.5" full_address="2526 W Van Buren St
Phoenix, AZ 85009" latitude="33.4514" longitude="-112.114" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-0tJ4FwcNtJjil-ZUTy30Q" name="Cafe No 9" categories="Food,Coffee & Tea,Internet Cafes,Breakfast & Brunch,Restaurants" city="Edinburgh" state="EDH" stars="4.5" full_address="9 Croall Place
Leith Walk
Leith
Edinburgh EH7 4LT" latitude="55.9616" longitude="-3.18036" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-1B-DEGkLE1kDj5ENAF2NQ" name="Prince Restaurant" categories="Modern European,Restaurants" city="Las Vegas" state="NV" stars="4.0" full_address="6795 W Flamingo Rd
Ste A
Las Vegas, NV 89103" latitude="36.1141" longitude="-115.241" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-1bOb2izeJBZjHC7NWxiPA" name="First Watch" categories="Breakfast & Brunch,Cafes,American (Traditional),Restaurants" city="Phoenix" state="AZ" stars="4.0" full_address="61 W. Thomas Road
Phoenix, AZ 85013" latitude="33.48" longitude="-112.077" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-1BzcQK-HDA6LVOThHMpsw" name="AJ's Pizzeria and Diner" categories="Pizza,Restaurants" city="Verona" state="WI" stars="4.0" full_address="300 South Main St
Verona, WI 53593" latitude="42.988" longitude="-89.5337" image_url="http://www.example.com/img.JPG"/> | ||
<restaurants business_id="-1ERbsOf9XOC9wGbZYFr7g" name="Toros Cantina & Gaming" categories="Mexican,Restaurants" city="Las Vegas" state="NV" stars="3.0" full_address="11760 W Charleston Blvd
Summerlin
Las Vegas, NV 89138" latitude="36.1595" longitude="-115.352" image_url="http://www.example.com/img.JPG"/> | ||
<users user_id="1111" first_name="John" last_name="Smith"/> | ||
<user_visit_history visit_history_id="1" user_id="1111" business_id="--qeSYxyn62mMjWvznNTdg" last_visited_time="2015-09-16 22:36:34.0"/> | ||
<user_visit_history visit_history_id="2" user_id="1111" business_id="--zgHBiQpr8H2ZqSdGmguQ" last_visited_time="2015-09-16 22:36:34.0"/> | ||
<user_visit_history visit_history_id="3" user_id="1111" business_id="-1B-DEGkLE1kDj5ENAF2NQ" last_visited_time="2015-09-16 22:36:34.0"/> | ||
</dataset> |