time_compare_test.go 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. package mhayaTime
  2. import (
  3. "testing"
  4. )
  5. func TestMhayaTime_IsNow(t *testing.T) {
  6. now := Now()
  7. t.Logf("result = %v", now.IsNow())
  8. }
  9. func TestMhayaTime_IsFuture(t *testing.T) {
  10. now := Now()
  11. t.Logf("result = %v", now.IsFuture())
  12. }
  13. func TestMhayaTime_IsPast(t *testing.T) {
  14. now := Now()
  15. t.Logf("result = %v", now.IsPast())
  16. }
  17. func TestMhayaTime_IsLeapYear(t *testing.T) {
  18. now := Now()
  19. t.Logf("result = %v", now.IsLeapYear())
  20. }
  21. func TestMhayaTime_IsLongYear(t *testing.T) {
  22. now := Now()
  23. t.Logf("result = %v", now.IsLongYear())
  24. }
  25. func TestMhayaTime_IsJanuary(t *testing.T) {
  26. now := Now()
  27. t.Logf("result = %v", now.IsJanuary())
  28. }
  29. func TestMhayaTime_IsFebruary(t *testing.T) {
  30. now := Now()
  31. t.Logf("result = %v", now.IsFebruary())
  32. }
  33. func TestMhayaTime_IsMarch(t *testing.T) {
  34. now := Now()
  35. t.Logf("result = %v", now.IsMarch())
  36. }
  37. func TestMhayaTime_IsApril(t *testing.T) {
  38. now := Now()
  39. t.Logf("result = %v", now.IsApril())
  40. }
  41. func TestMhayaTime_IsMay(t *testing.T) {
  42. now := Now()
  43. t.Logf("result = %v", now.IsMay())
  44. }
  45. func TestMhayaTime_IsJune(t *testing.T) {
  46. now := Now()
  47. t.Logf("result = %v", now.IsJune())
  48. }
  49. func TestMhayaTime_IsJuly(t *testing.T) {
  50. now := Now()
  51. t.Logf("result = %v", now.IsJuly())
  52. }
  53. func TestMhayaTime_IsAugust(t *testing.T) {
  54. now := Now()
  55. t.Logf("result = %v", now.IsAugust())
  56. }
  57. func TestMhayaTime_IsSeptember(t *testing.T) {
  58. now := Now()
  59. t.Logf("result = %v", now.IsSeptember())
  60. }
  61. func TestMhayaTime_IsOctober(t *testing.T) {
  62. now := Now()
  63. t.Logf("result = %v", now.IsOctober())
  64. }
  65. func TestMhayaTime_IsDecember(t *testing.T) {
  66. now := Now()
  67. t.Logf("result = %v", now.IsDecember())
  68. }
  69. func TestMhayaTime_IsMonday(t *testing.T) {
  70. now := Now()
  71. t.Logf("result = %v", now.IsMonday())
  72. }
  73. func TestMhayaTime_IsTuesday(t *testing.T) {
  74. now := Now()
  75. t.Logf("result = %v", now.IsTuesday())
  76. }
  77. func TestMhayaTime_IsWednesday(t *testing.T) {
  78. now := Now()
  79. t.Logf("result = %v", now.IsWednesday())
  80. }
  81. func TestMhayaTime_IsThursday(t *testing.T) {
  82. now := Now()
  83. t.Logf("result = %v", now.IsThursday())
  84. }
  85. func TestMhayaTime_IsFriday(t *testing.T) {
  86. now := Now()
  87. t.Logf("result = %v", now.IsFriday())
  88. }
  89. func TestMhayaTime_IsSaturday(t *testing.T) {
  90. now := Now()
  91. t.Logf("result = %v", now.IsSaturday())
  92. }
  93. func TestMhayaTime_IsSunday(t *testing.T) {
  94. now := Now()
  95. t.Logf("result = %v", now.IsSunday())
  96. }
  97. func TestMhayaTime_IsWeekday(t *testing.T) {
  98. now := Now()
  99. t.Logf("result = %v", now.IsWeekday())
  100. }
  101. func TestMhayaTime_IsWeekend(t *testing.T) {
  102. now := Now()
  103. t.Logf("result = %v", now.IsWeekend())
  104. }
  105. func TestMhayaTime_IsYesterday(t *testing.T) {
  106. now := Now()
  107. t.Logf("result = %v", now.IsYesterday())
  108. }
  109. func TestMhayaTime_IsYesterday1(t *testing.T) {
  110. now := Now()
  111. now.SubDay()
  112. t.Logf("result = %v", now.IsYesterday())
  113. }
  114. func TestMhayaTime_IsToday(t *testing.T) {
  115. now := Now()
  116. t.Logf("result = %v", now.IsToday())
  117. }
  118. func TestMhayaTime_IsTomorrow(t *testing.T) {
  119. now := Now()
  120. t.Logf("result = %v", now.IsTomorrow())
  121. }