Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Translation fixes for BA in master #344

Merged
merged 6 commits into from
Dec 14, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
VERSION_NAME=2.0.7-SNAPSHOT
VERSION_NAME=2.0.8-SNAPSHOT
VERSION_CODE=1
GROUP=org.smartregister
POM_SETTING_DESCRIPTION=OpenSRP Client Chw Core Library
Expand Down
6 changes: 3 additions & 3 deletions opensrp-chw-core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -211,22 +211,22 @@ dependencies {
exclude group: 'org.smartregister', module: 'opensrp-client-family'
}

api('org.smartregister:opensrp-client-chw-malaria:1.2.18-SNAPSHOT@aar') {
api('org.smartregister:opensrp-client-chw-malaria:1.2.19-SNAPSHOT@aar') {
transitive = true
exclude group: 'org.smartregister', module: 'opensrp-client-core'
exclude group: 'org.smartregister', module: 'opensrp-client-native-form'
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'com.android.support', module: 'appcompat-v7'
}

api('org.smartregister:opensrp-chw-family-planning:1.0.26-SNAPSHOT@aar') {
api('org.smartregister:opensrp-chw-family-planning:1.0.27-SNAPSHOT@aar') {
transitive = true
exclude group: 'org.smartregister', module: 'opensrp-client-core'
exclude group: 'org.smartregister', module: 'opensrp-client-native-form'
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'com.android.support', module: 'appcompat-v7'
}
api('org.smartregister:opensrp-client-chw-referral:1.3.5-SNAPSHOT@aar') {
api('org.smartregister:opensrp-client-chw-referral:1.3.6-SNAPSHOT@aar') {
transitive = true
exclude group: 'org.smartregister', module: 'opensrp-client-core'
exclude group: 'org.smartregister', module: 'opensrp-client-native-form'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,4 +112,9 @@ private void switchViews(View dueOnlyLayout, boolean isPress) {
protected void initializePresenter() {
presenter = new CoreAllClientsRegisterFragmentPresenter(this, new OpdRegisterFragmentModel());
}

@Override
protected int getToolBarTitle() {
return R.string.menu_all_clients;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
package org.smartregister.chw.core.fragment;


import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
import org.mockito.Mock;
import org.mockito.Mockito;
import org.mockito.MockitoAnnotations;
import org.robolectric.util.ReflectionHelpers;
import org.smartregister.chw.core.BaseUnitTest;
import org.smartregister.chw.core.R;
import org.smartregister.chw.core.presenter.CoreAllClientsRegisterFragmentPresenter;

public class CoreAllClientsRegisterFragmentTest extends BaseUnitTest {


@Mock
private CoreAllClientsRegisterFragmentPresenter presenter;

private CoreAllClientsRegisterFragment fragment;

@Before
public void setUp() {
MockitoAnnotations.initMocks(this);
fragment = Mockito.mock(CoreAllClientsRegisterFragment.class, Mockito.CALLS_REAL_METHODS);
ReflectionHelpers.setField(fragment, "presenter", presenter);
}

@Test
public void presenterInitializesCorrectly() {
fragment.initializePresenter();
Assert.assertNotNull(presenter);
}

@Test
public void testGetToolbarTitle() {
int title = fragment.getToolBarTitle();
Assert.assertEquals(R.string.menu_all_clients, title);
}
}