Advertisement
EvgeniiKraaaaaaaav

TEST FOR SALESMAN

Sep 12th, 2019
197
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Kotlin 2.32 KB | None | 0 0
  1.  
  2.  
  3. class TravelTest {
  4.   internal var ad = ("123 Main Street St. Louisville OH 43071,432 Main Long Road St. Louisville OH 43071,786 High Street Pollocksville NY 56432,"
  5.                      + "54 Holy Grail Street Niagara Town ZP 32908,3200 Main Rd. Bern AE 56210,1 Gordon St. Atlanta RE 13000,"
  6.                      + "10 Pussy Cat Rd. Chicago EX 34342,10 Gordon St. Atlanta RE 13000,58 Gordon Road Atlanta RE 13000,"
  7.                      + "22 Tokyo Av. Tedmondville SW 43098,674 Paris bd. Abbeville AA 45521,10 Surta Alley Goodtown GG 30654,"
  8.                      + "45 Holy Grail Al. Niagara Town ZP 32908,320 Main Al. Bern AE 56210,14 Gordon Park Atlanta RE 13000,"
  9.                      + "100 Pussy Cat Rd. Chicago EX 34342,2 Gordon St. Atlanta RE 13000,5 Gordon Road Atlanta RE 13000,"
  10.                      + "2200 Tokyo Av. Tedmondville SW 43098,67 Paris St. Abbeville AA 45521,11 Surta Avenue Goodtown GG 30654,"
  11.                      + "45 Holy Grail Al. Niagara Town ZP 32918,320 Main Al. Bern AE 56215,14 Gordon Park Atlanta RE 13200,"
  12.                      + "100 Pussy Cat Rd. Chicago EX 34345,2 Gordon St. Atlanta RE 13222,5 Gordon Road Atlanta RE 13001,"
  13.                      + "2200 Tokyo Av. Tedmondville SW 43198,67 Paris St. Abbeville AA 45522,11 Surta Avenue Goodville GG 30655,"
  14.                      + "2222 Tokyo Av. Tedmondville SW 43198,670 Paris St. Abbeville AA 45522,114 Surta Avenue Goodville GG 30655,"
  15.                      + "2 Holy Grail Street Niagara Town ZP 32908,3 Main Rd. Bern AE 56210,77 Gordon St. Atlanta RE 13000")
  16.   internal var code = ("OH 43071,NY 56432,ZP 32908,AE 56210,RE 13000,EX 34342,SW 43098,AA 45521,GG 30654,ZP 32908,AE 56215,RE 13200,EX 34345," + "RE 13222,RE 13001,SW 43198,AA 45522,GG 30655,XX 32321,YY 45098")
  17.   private fun testing(actual:String, expected:String) {
  18.     assertEquals(expected, actual)
  19.   }
  20.   @Test
  21.   fun test1() {
  22.     println("Fixed Tests: travel")
  23.     testing(travel(ad, "AA 45522"), "AA 45522:Paris St. Abbeville,Paris St. Abbeville/67,670")
  24.     testing(travel(ad, "EX 34342"), "EX 34342:Pussy Cat Rd. Chicago,Pussy Cat Rd. Chicago/10,100")
  25.     testing(travel(ad, "EX 34345"), "EX 34345:Pussy Cat Rd. Chicago/100")
  26.     testing(travel(ad, "AA 45521"), "AA 45521:Paris bd. Abbeville,Paris St. Abbeville/674,67")
  27.     testing(travel(ad, "AE 56215"), "AE 56215:Main Al. Bern/320")
  28.   }
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement