Решение на ExpireMap от Илия Ячев
Обратно към всички решения
Към профила на Илия Ячев
Резултати
- 9 точки от тестове
- 0 бонус точки
- 9 точки общо
- 22 успешни тест(а)
- 3 неуспешни тест(а)
Код
Лог от изпълнението
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
panic: test timed out
goroutine 15 [running]:
testing.alarm()
/usr/local/lib/go/src/pkg/testing/testing.go:533 +0x44
created by time.goFunc
/usr/local/lib/go/src/pkg/time/sleep.go:122 +0x45
goroutine 1 [chan receive]:
testing.RunTests(0x8147e94, 0x81c2ba0, 0x19, 0x19, 0x1, ...)
/usr/local/lib/go/src/pkg/testing/testing.go:434 +0x69f
testing.Main(0x8147e94, 0x81c2ba0, 0x19, 0x19, 0x81c5600, ...)
/usr/local/lib/go/src/pkg/testing/testing.go:365 +0x69
main.main()
_/tmp/d20141204-6466-10cyed2/_test/_testmain.go:91 +0x81
goroutine 4 [sleep]:
time.Sleep(0x3c336080, 0x0)
/usr/local/lib/go/src/pkg/runtime/ztime_linux_386.c:19 +0x3a
_/tmp/d20141204-6466-10cyed2.TestSizes(0x1837a1e0)
/tmp/d20141204-6466-10cyed2/solution_test.go:111 +0x337
testing.tRunner(0x1837a1e0, 0x81c2bb8)
/usr/local/lib/go/src/pkg/testing/testing.go:353 +0x87
created by testing.RunTests
/usr/local/lib/go/src/pkg/testing/testing.go:433 +0x684
goroutine 5 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x18348630)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 6 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x18348660)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 7 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x18348690)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 8 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x183486c0)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 9 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x183486f0)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 10 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x18348720)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 11 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x18348750)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 12 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x18348780)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 13 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x183487b0)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
goroutine 14 [select]:
_/tmp/d20141204-6466-10cyed2.func·001(0x183487e0)
/tmp/d20141204-6466-10cyed2/solution.go:60 +0x1b5
created by _/tmp/d20141204-6466-10cyed2.(*ExpireMap).Set
/tmp/d20141204-6466-10cyed2/solution.go:71 +0x278
exit status 2
FAIL _/tmp/d20141204-6466-10cyed2 1.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.122s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.172s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.051s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.112s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.062s
--- FAIL: TestExpiredChanWhenNoOneIsReading-2 (0.06 seconds)
solution_test.go:554: Wrong key expired
FAIL
exit status 1
FAIL _/tmp/d20141204-6466-10cyed2 0.072s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.112s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.132s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.172s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.012s
PASS
ok _/tmp/d20141204-6466-10cyed2 0.272s
--- FAIL: TestStringMethods-2 (0.00 seconds)
solution_test.go:948: ToUpper for key did not return an error
solution_test.go:952: ToLower for key did not return an error
solution_test.go:948: ToUpper for key did not return an error
solution_test.go:952: ToLower for key did not return an error
FAIL
exit status 1
FAIL _/tmp/d20141204-6466-10cyed2 0.021s
История (2 версии и 3 коментара)
Илия обнови решението на 17.11.2014 01:03 (преди над 3 години)
Илия обнови решението на 18.11.2014 00:10 (преди над 3 години)