Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
AloqaIM-Android
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
AloqaIM-Android
Commits
aaf1bedd
Unverified
Commit
aaf1bedd
authored
Aug 24, 2018
by
Lucio Maciel
Committed by
GitHub
Aug 24, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1614 from RocketChat/project/fix-building-error
[FIX] Building error
parents
8c31dff7
4a534c96
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
9 deletions
+18
-9
ChatRoomFragmentTest.kt
...a/chat/rocket/android/chatroom/ui/ChatRoomFragmentTest.kt
+16
-7
AppModule.kt
.../main/java/chat/rocket/android/dagger/module/AppModule.kt
+1
-1
build.gradle
build.gradle
+1
-1
No files found.
app/src/androidTest/java/chat/rocket/android/chatroom/ui/ChatRoomFragmentTest.kt
View file @
aaf1bedd
...
@@ -24,35 +24,44 @@ class ChatRoomFragmentTest {
...
@@ -24,35 +24,44 @@ class ChatRoomFragmentTest {
@Before
@Before
fun
stubAllExternalIntents
()
{
fun
stubAllExternalIntents
()
{
val
activityIntent
=
InstrumentationRegistry
.
getTargetContext
().
chatRoomIntent
(
"id"
,
"name"
,
"type"
,
false
,
0L
)
val
activityIntent
=
InstrumentationRegistry
.
getTargetContext
()
.
chatRoomIntent
(
"id"
,
"name"
,
"type"
,
false
,
0L
)
activityRule
.
launchActivity
(
activityIntent
)
activityRule
.
launchActivity
(
activityIntent
)
intending
(
not
(
isInternal
())).
respondWith
(
ActivityResult
(
Activity
.
RESULT_OK
,
null
))
intending
(
not
(
isInternal
())).
respondWith
(
ActivityResult
(
Activity
.
RESULT_OK
,
null
))
}
}
@Test
@Test
fun
showFileSelection_nonNullFiltersAreApplied
()
{
fun
showFileSelection_nonNullFiltersAreApplied
()
{
val
fragment
=
activityRule
.
activity
.
supportFragmentManager
.
findFragmentByTag
(
ChatRoomActivity
.
TAG_CHAT_ROOM_FRAGMENT
)
as
ChatRoomFragment
val
fragment
=
activityRule
.
activity
.
supportFragmentManager
.
findFragmentByTag
(
"ChatRoomFragment"
)
as
ChatRoomFragment
val
filters
=
arrayOf
(
"image/*"
)
val
filters
=
arrayOf
(
"image/*"
)
fragment
.
showFileSelection
(
filters
)
fragment
.
showFileSelection
(
filters
)
intended
(
allOf
(
intended
(
allOf
(
hasAction
(
Intent
.
ACTION_GET_CONTENT
),
hasAction
(
Intent
.
ACTION_GET_CONTENT
),
hasType
(
"*/*"
),
hasType
(
"*/*"
),
hasCategories
(
setOf
(
Intent
.
CATEGORY_OPENABLE
)),
hasCategories
(
setOf
(
Intent
.
CATEGORY_OPENABLE
)),
hasExtra
(
Intent
.
EXTRA_MIME_TYPES
,
filters
)))
hasExtra
(
Intent
.
EXTRA_MIME_TYPES
,
filters
)
)
)
}
}
@Test
@Test
fun
showFileSelection_nullFiltersAreNotApplied
()
{
fun
showFileSelection_nullFiltersAreNotApplied
()
{
val
fragment
=
activityRule
.
activity
.
supportFragmentManager
.
findFragmentByTag
(
ChatRoomActivity
.
TAG_CHAT_ROOM_FRAGMENT
)
as
ChatRoomFragment
val
fragment
=
activityRule
.
activity
.
supportFragmentManager
.
findFragmentByTag
(
"ChatRoomFragment"
)
as
ChatRoomFragment
fragment
.
showFileSelection
(
null
)
fragment
.
showFileSelection
(
null
)
intended
(
allOf
(
intended
(
allOf
(
hasAction
(
Intent
.
ACTION_GET_CONTENT
),
hasAction
(
Intent
.
ACTION_GET_CONTENT
),
hasType
(
"*/*"
),
hasType
(
"*/*"
),
hasCategories
(
setOf
(
Intent
.
CATEGORY_OPENABLE
)),
hasCategories
(
setOf
(
Intent
.
CATEGORY_OPENABLE
)),
not
(
hasExtraWithKey
(
Intent
.
EXTRA_MIME_TYPES
))))
not
(
hasExtraWithKey
(
Intent
.
EXTRA_MIME_TYPES
))
)
)
}
}
}
}
\ No newline at end of file
app/src/main/java/chat/rocket/android/dagger/module/AppModule.kt
View file @
aaf1bedd
...
@@ -35,6 +35,7 @@ import chat.rocket.android.server.domain.MultiServerTokenRepository
...
@@ -35,6 +35,7 @@ import chat.rocket.android.server.domain.MultiServerTokenRepository
import
chat.rocket.android.server.domain.PermissionsRepository
import
chat.rocket.android.server.domain.PermissionsRepository
import
chat.rocket.android.server.domain.RoomRepository
import
chat.rocket.android.server.domain.RoomRepository
import
chat.rocket.android.server.domain.SettingsRepository
import
chat.rocket.android.server.domain.SettingsRepository
import
chat.rocket.android.server.domain.TokenRepository
import
chat.rocket.android.server.domain.UsersRepository
import
chat.rocket.android.server.domain.UsersRepository
import
chat.rocket.android.server.infraestructure.JobSchedulerInteractorImpl
import
chat.rocket.android.server.infraestructure.JobSchedulerInteractorImpl
import
chat.rocket.android.server.infraestructure.MemoryActiveUsersRepository
import
chat.rocket.android.server.infraestructure.MemoryActiveUsersRepository
...
@@ -57,7 +58,6 @@ import chat.rocket.common.model.TimestampAdapter
...
@@ -57,7 +58,6 @@ import chat.rocket.common.model.TimestampAdapter
import
chat.rocket.common.util.CalendarISO8601Converter
import
chat.rocket.common.util.CalendarISO8601Converter
import
chat.rocket.common.util.Logger
import
chat.rocket.common.util.Logger
import
chat.rocket.common.util.PlatformLogger
import
chat.rocket.common.util.PlatformLogger
import
chat.rocket.core.TokenRepository
import
chat.rocket.core.internal.AttachmentAdapterFactory
import
chat.rocket.core.internal.AttachmentAdapterFactory
import
chat.rocket.core.internal.ReactionsAdapter
import
chat.rocket.core.internal.ReactionsAdapter
import
com.facebook.drawee.backends.pipeline.DraweeConfig
import
com.facebook.drawee.backends.pipeline.DraweeConfig
...
...
build.gradle
View file @
aaf1bedd
...
@@ -10,7 +10,7 @@ buildscript {
...
@@ -10,7 +10,7 @@ buildscript {
}
}
dependencies
{
dependencies
{
classpath
'com.android.tools.build:gradle:3.3.0-alpha0
6
'
classpath
'com.android.tools.build:gradle:3.3.0-alpha0
5
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}"
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}"
classpath
"org.jetbrains.dokka:dokka-gradle-plugin:${versions.dokka}"
classpath
"org.jetbrains.dokka:dokka-gradle-plugin:${versions.dokka}"
classpath
'com.google.gms:google-services:4.0.2'
classpath
'com.google.gms:google-services:4.0.2'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment