diff --git a/buildsystem/dependencies.gradle b/buildsystem/dependencies.gradle
index ab6d7e4e..99aa67b6 100644
--- a/buildsystem/dependencies.gradle
+++ b/buildsystem/dependencies.gradle
@@ -46,13 +46,15 @@ if (alias == null) {
alias = ''
}
+def kakaoVersion = new File('buildsystem/version').text.trim() + alias
+
ext.kakao = [
group : 'com.agoda.kakao',
artifact : 'kakao',
name : 'kakao',
description : 'Kotlin based DSL for fluent AT with Espresso',
- version : "2.3.2$alias",
- version_desc : "Kakao 2.3.2$alias",
+ version : "$kakaoVersion",
+ version_desc : "Kakao $kakaoVersion",
site : 'https://github.com/agoda-com/Kakao',
github : 'https://github.com/agoda-com/Kakao.git'
]
diff --git a/buildsystem/version b/buildsystem/version
new file mode 100644
index 00000000..45674f16
--- /dev/null
+++ b/buildsystem/version
@@ -0,0 +1 @@
+2.3.3
\ No newline at end of file
diff --git a/docs/kakao/alltypes/index.md b/docs/kakao/alltypes/index.md
index 11796262..34878a1d 100644
--- a/docs/kakao/alltypes/index.md
+++ b/docs/kakao/alltypes/index.md
@@ -129,6 +129,7 @@
| [com.agoda.kakao.text.TextViewAssertions](../com.agoda.kakao.text/-text-view-assertions/index.md) | Provides text based assertions for views |
| [com.agoda.kakao.picker.time.TimePickerAction](../com.agoda.kakao.picker.time/-time-picker-action/index.md) | Provides actions for time picker |
| [com.agoda.kakao.picker.time.TimePickerAssertion](../com.agoda.kakao.picker.time/-time-picker-assertion/index.md) | Provides assertions for time picker |
+| [com.agoda.kakao.common.matchers.ToolbarNavigationMatcher](../com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/index.md) | |
| [com.agoda.kakao.common.matchers.ToolbarSubtitleMatcher](../com.agoda.kakao.common.matchers/-toolbar-subtitle-matcher/index.md) | |
| [com.agoda.kakao.common.matchers.ToolbarTitleMatcher](../com.agoda.kakao.common.matchers/-toolbar-title-matcher/index.md) | |
| [com.agoda.kakao.toolbar.ToolbarViewActions](../com.agoda.kakao.toolbar/-toolbar-view-actions.md) | Provides actions for Toolbar |
diff --git a/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/-init-.md b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/-init-.md
new file mode 100644
index 00000000..91d0dbff
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/-init-.md
@@ -0,0 +1,7 @@
+[kakao](../../index.md) / [com.agoda.kakao.common.matchers](../index.md) / [ToolbarNavigationMatcher](index.md) / [<init>](./-init-.md)
+
+# <init>
+
+`ToolbarNavigationMatcher(drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`)`
+`ToolbarNavigationMatcher(@DrawableRes resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)`
+`ToolbarNavigationMatcher(toBitmap: ((drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`) -> `[`Bitmap`](https://developer.android.com/reference/android/graphics/Bitmap.html)`)? = null)`
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/describe-to.md b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/describe-to.md
new file mode 100644
index 00000000..dd3ea4e9
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/describe-to.md
@@ -0,0 +1,5 @@
+[kakao](../../index.md) / [com.agoda.kakao.common.matchers](../index.md) / [ToolbarNavigationMatcher](index.md) / [describeTo](./describe-to.md)
+
+# describeTo
+
+`fun describeTo(desc: Description): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/drawable.md b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/drawable.md
new file mode 100644
index 00000000..80bc7c70
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/drawable.md
@@ -0,0 +1,5 @@
+[kakao](../../index.md) / [com.agoda.kakao.common.matchers](../index.md) / [ToolbarNavigationMatcher](index.md) / [drawable](./drawable.md)
+
+# drawable
+
+`var drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`?`
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/index.md b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/index.md
new file mode 100644
index 00000000..a0d1b5c8
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/index.md
@@ -0,0 +1,25 @@
+[kakao](../../index.md) / [com.agoda.kakao.common.matchers](../index.md) / [ToolbarNavigationMatcher](./index.md)
+
+# ToolbarNavigationMatcher
+
+`class ToolbarNavigationMatcher : BoundedMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`, Toolbar>`
+
+### Constructors
+
+| Name | Summary |
+|---|---|
+| [<init>](-init-.md) | `ToolbarNavigationMatcher(drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`)`
`ToolbarNavigationMatcher(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)`
`ToolbarNavigationMatcher(toBitmap: ((drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`) -> `[`Bitmap`](https://developer.android.com/reference/android/graphics/Bitmap.html)`)? = null)` |
+
+### Properties
+
+| Name | Summary |
+|---|---|
+| [drawable](drawable.md) | `var drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`?` |
+| [resId](res-id.md) | `var resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) |
+
+### Functions
+
+| Name | Summary |
+|---|---|
+| [describeTo](describe-to.md) | `fun describeTo(desc: Description): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
+| [matchesSafely](matches-safely.md) | `fun matchesSafely(view: Toolbar): `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) |
diff --git a/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/matches-safely.md b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/matches-safely.md
new file mode 100644
index 00000000..aab3831b
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/matches-safely.md
@@ -0,0 +1,5 @@
+[kakao](../../index.md) / [com.agoda.kakao.common.matchers](../index.md) / [ToolbarNavigationMatcher](index.md) / [matchesSafely](./matches-safely.md)
+
+# matchesSafely
+
+`protected fun matchesSafely(view: Toolbar): `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/res-id.md b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/res-id.md
new file mode 100644
index 00000000..66614f50
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.matchers/-toolbar-navigation-matcher/res-id.md
@@ -0,0 +1,5 @@
+[kakao](../../index.md) / [com.agoda.kakao.common.matchers](../index.md) / [ToolbarNavigationMatcher](index.md) / [resId](./res-id.md)
+
+# resId
+
+`var resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.matchers/index.md b/docs/kakao/com.agoda.kakao.common.matchers/index.md
index b0b87dad..89a2bec5 100644
--- a/docs/kakao/com.agoda.kakao.common.matchers/index.md
+++ b/docs/kakao/com.agoda.kakao.common.matchers/index.md
@@ -27,6 +27,7 @@
| [TextInputLayoutCounterEnabledMatcher](-text-input-layout-counter-enabled-matcher/index.md) | `class TextInputLayoutCounterEnabledMatcher : TypeSafeMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`>` |
| [TextInputLayoutErrorEnabledMatcher](-text-input-layout-error-enabled-matcher/index.md) | `class TextInputLayoutErrorEnabledMatcher : TypeSafeMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`>` |
| [TextInputLayoutHintEnabledMatcher](-text-input-layout-hint-enabled-matcher/index.md) | `class TextInputLayoutHintEnabledMatcher : TypeSafeMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`>` |
+| [ToolbarNavigationMatcher](-toolbar-navigation-matcher/index.md) | `class ToolbarNavigationMatcher : BoundedMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`, Toolbar>` |
| [ToolbarSubtitleMatcher](-toolbar-subtitle-matcher/index.md) | `class ToolbarSubtitleMatcher : BoundedMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`, Toolbar>` |
| [ToolbarTitleMatcher](-toolbar-title-matcher/index.md) | `class ToolbarTitleMatcher : BoundedMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`, Toolbar>` |
| [ViewPager2AdapterSizeMatcher](-view-pager2-adapter-size-matcher/index.md) | `class ViewPager2AdapterSizeMatcher : BoundedMatcher<`[`View`](https://developer.android.com/reference/android/view/View.html)`, ViewPager2>`
Matches ViewPager2 with count of children |
diff --git a/docs/kakao/com.agoda.kakao.common.utilities/get-resource-color.md b/docs/kakao/com.agoda.kakao.common.utilities/get-resource-color.md
new file mode 100644
index 00000000..0001bc01
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.utilities/get-resource-color.md
@@ -0,0 +1,5 @@
+[kakao](../index.md) / [com.agoda.kakao.common.utilities](index.md) / [getResourceColor](./get-resource-color.md)
+
+# getResourceColor
+
+`fun getResourceColor(@ColorRes resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.utilities/get-resource-drawable.md b/docs/kakao/com.agoda.kakao.common.utilities/get-resource-drawable.md
new file mode 100644
index 00000000..23c5cf07
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.utilities/get-resource-drawable.md
@@ -0,0 +1,5 @@
+[kakao](../index.md) / [com.agoda.kakao.common.utilities](index.md) / [getResourceDrawable](./get-resource-drawable.md)
+
+# getResourceDrawable
+
+`fun getResourceDrawable(@DrawableRes resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`?`
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.utilities/get-resource-string.md b/docs/kakao/com.agoda.kakao.common.utilities/get-resource-string.md
new file mode 100644
index 00000000..e2819e24
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.utilities/get-resource-string.md
@@ -0,0 +1,5 @@
+[kakao](../index.md) / [com.agoda.kakao.common.utilities](index.md) / [getResourceString](./get-resource-string.md)
+
+# getResourceString
+
+`fun getResourceString(@StringRes resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`!`
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.common.utilities/index.md b/docs/kakao/com.agoda.kakao.common.utilities/index.md
new file mode 100644
index 00000000..ae23a2c5
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.common.utilities/index.md
@@ -0,0 +1,11 @@
+[kakao](../index.md) / [com.agoda.kakao.common.utilities](./index.md)
+
+## Package com.agoda.kakao.common.utilities
+
+### Functions
+
+| Name | Summary |
+|---|---|
+| [getResourceColor](get-resource-color.md) | `fun getResourceColor(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) |
+| [getResourceDrawable](get-resource-drawable.md) | `fun getResourceDrawable(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`?` |
+| [getResourceString](get-resource-string.md) | `fun getResourceString(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`!` |
diff --git a/docs/kakao/com.agoda.kakao.edit/-k-text-input-layout/index.md b/docs/kakao/com.agoda.kakao.edit/-k-text-input-layout/index.md
index d55de9e4..8ca108bf 100644
--- a/docs/kakao/com.agoda.kakao.edit/-k-text-input-layout/index.md
+++ b/docs/kakao/com.agoda.kakao.edit/-k-text-input-layout/index.md
@@ -34,8 +34,8 @@ View with TextInputLayoutAssertions
| Name | Summary |
|---|---|
| [hasCounterMaxLength](../-text-input-layout-assertions/has-counter-max-length.md) | `open fun hasCounterMaxLength(length: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
-| [hasError](../-text-input-layout-assertions/has-error.md) | `open fun hasError(error: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
-| [hasHint](../-text-input-layout-assertions/has-hint.md) | `open fun hasHint(hint: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if this input layout has given hint |
+| [hasError](../-text-input-layout-assertions/has-error.md) | `open fun hasError(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasError(error: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
+| [hasHint](../-text-input-layout-assertions/has-hint.md) | `open fun hasHint(hint: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if this input layout has given hint`open fun hasHint(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
| [invoke](../../com.agoda.kakao.common.views/-k-base-view/invoke.md) | `operator fun invoke(function: `[`T`](../../com.agoda.kakao.common.views/-k-base-view/index.md#T)`.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Operator that allows usage of DSL style |
| [isCounterDisabled](../-text-input-layout-assertions/is-counter-disabled.md) | `open fun isCounterDisabled(): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
| [isCounterEnabled](../-text-input-layout-assertions/is-counter-enabled.md) | `open fun isCounterEnabled(): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
diff --git a/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-error.md b/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-error.md
index 2080520d..1f0f68ce 100644
--- a/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-error.md
+++ b/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-error.md
@@ -2,4 +2,5 @@
# hasError
+`open fun hasError(@StringRes resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasError(error: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-hint.md b/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-hint.md
index 2dd04177..7f67fcad 100644
--- a/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-hint.md
+++ b/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/has-hint.md
@@ -10,3 +10,4 @@ Checks if this input layout has given hint
`hint` -
* hint text to be checked
+`open fun hasHint(@StringRes resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/index.md b/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/index.md
index a15e07f4..38dc5f8a 100644
--- a/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/index.md
+++ b/docs/kakao/com.agoda.kakao.edit/-text-input-layout-assertions/index.md
@@ -18,8 +18,8 @@ Provides assertions for TextInputLayout
| Name | Summary |
|---|---|
| [hasCounterMaxLength](has-counter-max-length.md) | `open fun hasCounterMaxLength(length: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
-| [hasError](has-error.md) | `open fun hasError(error: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
-| [hasHint](has-hint.md) | `open fun hasHint(hint: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if this input layout has given hint |
+| [hasError](has-error.md) | `open fun hasError(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasError(error: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
+| [hasHint](has-hint.md) | `open fun hasHint(hint: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if this input layout has given hint`open fun hasHint(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
| [isCounterDisabled](is-counter-disabled.md) | `open fun isCounterDisabled(): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
| [isCounterEnabled](is-counter-enabled.md) | `open fun isCounterEnabled(): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
| [isErrorDisabled](is-error-disabled.md) | `open fun isErrorDisabled(): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
diff --git a/docs/kakao/com.agoda.kakao.toolbar/-k-toolbar/index.md b/docs/kakao/com.agoda.kakao.toolbar/-k-toolbar/index.md
index 13f4b12d..c65ceed5 100644
--- a/docs/kakao/com.agoda.kakao.toolbar/-k-toolbar/index.md
+++ b/docs/kakao/com.agoda.kakao.toolbar/-k-toolbar/index.md
@@ -29,6 +29,7 @@ View for acting and asserting on Toolbar
| Name | Summary |
|---|---|
+| [hasHomeAsUpIndicatorDrawable](../-toolbar-view-assertions/has-home-as-up-indicator-drawable.md) | `open fun hasHomeAsUpIndicatorDrawable(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasHomeAsUpIndicatorDrawable(drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if Toolbar has navigation icon |
| [hasSubtitle](../-toolbar-view-assertions/has-subtitle.md) | `open fun hasSubtitle(subtitle: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasSubtitle(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if Toolbar has subtitle |
| [hasTitle](../-toolbar-view-assertions/has-title.md) | `open fun hasTitle(title: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasTitle(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if Toolbar has title |
| [invoke](../../com.agoda.kakao.common.views/-k-base-view/invoke.md) | `operator fun invoke(function: `[`T`](../../com.agoda.kakao.common.views/-k-base-view/index.md#T)`.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Operator that allows usage of DSL style |
diff --git a/docs/kakao/com.agoda.kakao.toolbar/-toolbar-view-assertions/has-home-as-up-indicator-drawable.md b/docs/kakao/com.agoda.kakao.toolbar/-toolbar-view-assertions/has-home-as-up-indicator-drawable.md
new file mode 100644
index 00000000..20e43d67
--- /dev/null
+++ b/docs/kakao/com.agoda.kakao.toolbar/-toolbar-view-assertions/has-home-as-up-indicator-drawable.md
@@ -0,0 +1,17 @@
+[kakao](../../index.md) / [com.agoda.kakao.toolbar](../index.md) / [ToolbarViewAssertions](index.md) / [hasHomeAsUpIndicatorDrawable](./has-home-as-up-indicator-drawable.md)
+
+# hasHomeAsUpIndicatorDrawable
+
+`open fun hasHomeAsUpIndicatorDrawable(@DrawableRes resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
+
+Checks if Toolbar has navigation icon
+
+### Parameters
+
+`resId` - expected drawable resource id`open fun hasHomeAsUpIndicatorDrawable(drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
+
+Checks if Toolbar has navigation icon
+
+### Parameters
+
+`drawable` - expected drawable
\ No newline at end of file
diff --git a/docs/kakao/com.agoda.kakao.toolbar/-toolbar-view-assertions/index.md b/docs/kakao/com.agoda.kakao.toolbar/-toolbar-view-assertions/index.md
index 50af7cfd..3a269258 100644
--- a/docs/kakao/com.agoda.kakao.toolbar/-toolbar-view-assertions/index.md
+++ b/docs/kakao/com.agoda.kakao.toolbar/-toolbar-view-assertions/index.md
@@ -17,6 +17,7 @@ Provides assertion for Toolbar
| Name | Summary |
|---|---|
+| [hasHomeAsUpIndicatorDrawable](has-home-as-up-indicator-drawable.md) | `open fun hasHomeAsUpIndicatorDrawable(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasHomeAsUpIndicatorDrawable(drawable: `[`Drawable`](https://developer.android.com/reference/android/graphics/drawable/Drawable.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if Toolbar has navigation icon |
| [hasSubtitle](has-subtitle.md) | `open fun hasSubtitle(subtitle: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasSubtitle(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if Toolbar has subtitle |
| [hasTitle](has-title.md) | `open fun hasTitle(title: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
`open fun hasTitle(resId: `[`Int`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
Checks if Toolbar has title |
diff --git a/docs/kakao/index.md b/docs/kakao/index.md
index 9ca0c0d4..c160e509 100644
--- a/docs/kakao/index.md
+++ b/docs/kakao/index.md
@@ -13,6 +13,7 @@
| [com.agoda.kakao.common.assertions](com.agoda.kakao.common.assertions/index.md) | |
| [com.agoda.kakao.common.builders](com.agoda.kakao.common.builders/index.md) | |
| [com.agoda.kakao.common.matchers](com.agoda.kakao.common.matchers/index.md) | |
+| [com.agoda.kakao.common.utilities](com.agoda.kakao.common.utilities/index.md) | |
| [com.agoda.kakao.common.views](com.agoda.kakao.common.views/index.md) | |
| [com.agoda.kakao.delegate](com.agoda.kakao.delegate/index.md) | |
| [com.agoda.kakao.dialog](com.agoda.kakao.dialog/index.md) | |
diff --git a/docs/kakao/package-list b/docs/kakao/package-list
index 71b154a4..5eaf1ccc 100644
--- a/docs/kakao/package-list
+++ b/docs/kakao/package-list
@@ -10,6 +10,7 @@ com.agoda.kakao.common.actions
com.agoda.kakao.common.assertions
com.agoda.kakao.common.builders
com.agoda.kakao.common.matchers
+com.agoda.kakao.common.utilities
com.agoda.kakao.common.views
com.agoda.kakao.delegate
com.agoda.kakao.dialog
diff --git a/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/BackgroundColorMatcher.kt b/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/BackgroundColorMatcher.kt
index 1118a965..6a0279df 100644
--- a/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/BackgroundColorMatcher.kt
+++ b/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/BackgroundColorMatcher.kt
@@ -6,7 +6,7 @@ import android.graphics.Color
import android.graphics.drawable.ColorDrawable
import android.view.View
import androidx.annotation.ColorRes
-import androidx.core.content.ContextCompat
+import com.agoda.kakao.common.utilities.getResourceColor
import org.hamcrest.Description
import org.hamcrest.TypeSafeMatcher
@@ -28,7 +28,7 @@ class BackgroundColorMatcher(
return item?.let {
val expectedColor = if (resId != -1) {
- ContextCompat.getColor(it.context, resId)
+ getResourceColor(resId)
} else {
Color.parseColor(colorCode)
}
diff --git a/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/DrawableMatcher.kt b/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/DrawableMatcher.kt
index b98c248c..47692b2f 100644
--- a/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/DrawableMatcher.kt
+++ b/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/DrawableMatcher.kt
@@ -4,19 +4,17 @@ package com.agoda.kakao.common.matchers
import android.content.res.ColorStateList
import android.graphics.Bitmap
-import android.graphics.Canvas
import android.graphics.PorterDuff
-import android.graphics.drawable.BitmapDrawable
import android.graphics.drawable.Drawable
-import android.graphics.drawable.StateListDrawable
import android.os.Build
import android.view.View
import android.widget.ImageView
import androidx.annotation.ColorRes
import androidx.annotation.DrawableRes
-import androidx.core.content.ContextCompat
import androidx.core.graphics.drawable.DrawableCompat
import com.agoda.kakao.common.extentions.toBitmap
+import com.agoda.kakao.common.utilities.getResourceColor
+import com.agoda.kakao.common.utilities.getResourceDrawable
import org.hamcrest.Description
import org.hamcrest.TypeSafeMatcher
@@ -49,7 +47,7 @@ class DrawableMatcher(
}
return view?.let { imageView ->
- var expectedDrawable: Drawable? = drawable ?: ContextCompat.getDrawable(imageView.context, resId)
+ var expectedDrawable: Drawable? = drawable ?: getResourceDrawable(resId)
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP && expectedDrawable != null) {
expectedDrawable = DrawableCompat.wrap(expectedDrawable).mutate()
@@ -57,7 +55,7 @@ class DrawableMatcher(
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
tintColorId?.let { tintColorId ->
- val tintColor = ContextCompat.getColor(imageView.context, tintColorId)
+ val tintColor = getResourceColor(tintColorId)
expectedDrawable?.apply {
setTintList(ColorStateList.valueOf(tintColor))
setTintMode(PorterDuff.Mode.SRC_IN)
diff --git a/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/ToolbarNavigationMatcher.kt b/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/ToolbarNavigationMatcher.kt
index fd213306..bb20a62c 100644
--- a/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/ToolbarNavigationMatcher.kt
+++ b/kakao/src/main/kotlin/com/agoda/kakao/common/matchers/ToolbarNavigationMatcher.kt
@@ -1,18 +1,15 @@
package com.agoda.kakao.common.matchers
import android.graphics.Bitmap
-import android.graphics.Canvas
-import android.graphics.drawable.BitmapDrawable
import android.graphics.drawable.Drawable
-import android.graphics.drawable.StateListDrawable
import android.os.Build
import android.view.View
import androidx.annotation.DrawableRes
import androidx.appcompat.widget.Toolbar
-import androidx.core.content.ContextCompat
import androidx.core.graphics.drawable.DrawableCompat
import androidx.test.espresso.matcher.BoundedMatcher
import com.agoda.kakao.common.extentions.toBitmap
+import com.agoda.kakao.common.utilities.getResourceDrawable
import org.hamcrest.Description
class ToolbarNavigationMatcher(
@@ -39,7 +36,7 @@ class ToolbarNavigationMatcher(
return false
}
- var expectedDrawable: Drawable? = drawable ?: ContextCompat.getDrawable(view.context, resId)
+ var expectedDrawable: Drawable? = drawable ?: getResourceDrawable(resId)
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP && expectedDrawable != null) {
expectedDrawable = DrawableCompat.wrap(expectedDrawable).mutate()
diff --git a/kakao/src/main/kotlin/com/agoda/kakao/common/utilities/ContextUtils.kt b/kakao/src/main/kotlin/com/agoda/kakao/common/utilities/ContextUtils.kt
index e566dc5a..6364bb44 100644
--- a/kakao/src/main/kotlin/com/agoda/kakao/common/utilities/ContextUtils.kt
+++ b/kakao/src/main/kotlin/com/agoda/kakao/common/utilities/ContextUtils.kt
@@ -1,10 +1,13 @@
package com.agoda.kakao.common.utilities
-import android.content.Context
+import androidx.annotation.ColorRes
+import androidx.annotation.DrawableRes
import androidx.annotation.StringRes
+import androidx.core.content.ContextCompat
import androidx.test.platform.app.InstrumentationRegistry
-fun getResourceString(@StringRes resId: Int): String {
- val targetContext: Context = InstrumentationRegistry.getInstrumentation().targetContext
- return targetContext.resources.getString(resId)
-}
\ No newline at end of file
+fun getResourceString(@StringRes resId: Int) = InstrumentationRegistry.getInstrumentation().targetContext.resources.getString(resId)
+
+fun getResourceDrawable(@DrawableRes resId: Int) = ContextCompat.getDrawable(InstrumentationRegistry.getInstrumentation().targetContext, resId)
+
+fun getResourceColor(@ColorRes resId: Int) = ContextCompat.getColor(InstrumentationRegistry.getInstrumentation().targetContext, resId)
diff --git a/sample/src/androidTest/res/.DS_Store b/sample/src/androidTest/res/.DS_Store
deleted file mode 100644
index 9b9e28fd..00000000
Binary files a/sample/src/androidTest/res/.DS_Store and /dev/null differ