Skip to content

Commit 3d7032f

Browse files
authored
Merge pull request #121 from opensrp/update-core-and-fhir-versions
Update core and fhir model versions
2 parents 9494bf7 + dae47a2 commit 3d7032f

File tree

5 files changed

+14
-22
lines changed

5 files changed

+14
-22
lines changed

build.gradle

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ buildscript {
1212
dependencies {
1313
classpath "io.codearte.gradle.nexus:gradle-nexus-staging-plugin:0.11.0"
1414
classpath 'gradle.plugin.org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.10.2'
15-
classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.5"
1615
}
1716
}
1817

@@ -56,14 +55,13 @@ subprojects {
5655
google()
5756
jcenter()
5857
mavenCentral()
58+
mavenLocal()
5959
maven { url 'https://jitpack.io' }
6060
maven { url "http://acra.googlecode.com/svn/repository/releases" }
6161
maven { url "https://repo.maven.apache.org/maven2" }
6262
maven { url "http://cloudant.github.io/cloudant-sync-eap/repository" }
6363
maven { url 'https://oss.sonatype.org/content/repositories/snapshots/' }
6464
maven { url "https://s3.amazonaws.com/repo.commonsware.com" }
65-
maven { url 'https://dl.bintray.com/ibm-watson-health/ibm-fhir-server-releases'}
66-
mavenLocal()
6765
}
6866

6967
// Improve build server performance by allowing disabling of pre-dexing

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
VERSION_NAME=0.1.1-SNAPSHOT
1+
VERSION_NAME=0.1.2-SNAPSHOT
22
VERSION_CODE=1
33
GROUP=org.smartregister
44
POM_SETTING_DESCRIPTION=OpenSRP Client Reporting Library

opensrp-reporting/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ apply plugin: 'jacoco'
1414
apply plugin: 'com.github.kt3k.coveralls'
1515
apply plugin: 'com.android.library'
1616
apply plugin: 'maven-publish'
17-
apply plugin: "com.jfrog.bintray"
1817

1918
jacoco {
2019
toolVersion = "0.8.5"
@@ -70,6 +69,7 @@ android {
7069
exclude 'META-INF/ASL2.0'
7170
exclude 'META-INF/LICENSE.md'
7271
exclude 'META-INF/NOTICE.md'
72+
exclude 'META-INF/INDEX.LIST'
7373
}
7474

7575
testOptions {
@@ -95,7 +95,7 @@ artifacts {
9595
}
9696

9797
dependencies {
98-
implementation('org.smartregister:opensrp-client-core:1.15.4-SNAPSHOT@aar') {
98+
implementation('org.smartregister:opensrp-client-core:4.3.22-SNAPSHOT@aar') {
9999
transitive = true
100100
exclude group: 'com.github.bmelnychuk', module: 'atv'
101101
exclude group: 'com.google.guava', module: 'guava'
@@ -106,7 +106,7 @@ dependencies {
106106
exclude group: 'com.ibm.fhir', module: 'fhir-model'
107107
}
108108

109-
compileOnly 'com.ibm.fhir:fhir-model:4.2.3'
109+
compileOnly 'com.ibm.fhir:fhir-model:4.7.0'
110110

111111
implementation 'androidx.appcompat:appcompat:1.0.0'
112112
implementation 'androidx.legacy:legacy-support-v4:1.0.0'

opensrp-reporting/src/test/java/org/smartregister/reporting/dao/ReportIndicatorDaoImplTest.java

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public class ReportIndicatorDaoImplTest {
5959
private IndicatorQueryRepository indicatorQueryRepository;
6060
@Mock
6161
private CoreLibrary coreLibrary;
62-
@Mock
62+
6363
private AppProperties appProperties;
6464
@Mock
6565
private Context context;
@@ -68,6 +68,12 @@ public class ReportIndicatorDaoImplTest {
6868
public void setUp() {
6969
MockitoAnnotations.initMocks(this);
7070
reportIndicatorDao = new ReportIndicatorDaoImpl(indicatorQueryRepository, dailyIndicatorCountRepository, indicatorRepository);
71+
ReflectionHelpers.setStaticField(CoreLibrary.class, "instance", coreLibrary);
72+
73+
Mockito.when(coreLibrary.context()).thenReturn(context);
74+
appProperties = new AppProperties();
75+
appProperties.setProperty(Constants.ReportingConfig.SHOULD_ALLOW_ZERO_TALLIES, "true");
76+
Mockito.when(context.getAppProperties()).thenReturn(appProperties);
7177
}
7278

7379
@Test
@@ -112,13 +118,6 @@ public void testGenerateDailyIndicatorTalliesCallsSaveTalliesEqualToNumberOfRepo
112118
Repository repository = Mockito.mock(Repository.class);
113119
Mockito.doReturn(database).when(repository).getWritableDatabase();
114120

115-
ReflectionHelpers.setStaticField(CoreLibrary.class, "instance", coreLibrary);
116-
117-
Mockito.when(coreLibrary.context()).thenReturn(context);
118-
Mockito.when(context.getAppProperties()).thenReturn(appProperties);
119-
Mockito.when(appProperties.hasProperty(Constants.ReportingConfig.SHOULD_ALLOW_ZERO_TALLIES)).thenReturn(true);
120-
Mockito.when(appProperties.getPropertyBoolean(Constants.ReportingConfig.SHOULD_ALLOW_ZERO_TALLIES)).thenReturn(true);
121-
122121
ReportingLibrary reportingLibrarySpy = Mockito.mock(ReportingLibrary.class);
123122
ReflectionHelpers.setStaticField(ReportingLibrary.class, "instance", reportingLibrarySpy);
124123

@@ -157,12 +156,6 @@ public void testGenerateDailyIndicatorTalliesCallsSaveTalliesEqualToNumberOfRepo
157156

158157
@Test
159158
public void saveTalliesGeneratesTallyObject() {
160-
ReflectionHelpers.setStaticField(CoreLibrary.class, "instance", coreLibrary);
161-
162-
Mockito.when(coreLibrary.context()).thenReturn(context);
163-
Mockito.when(context.getAppProperties()).thenReturn(appProperties);
164-
Mockito.when(appProperties.hasProperty(Constants.ReportingConfig.SHOULD_ALLOW_ZERO_TALLIES)).thenReturn(true);
165-
Mockito.when(appProperties.getPropertyBoolean(Constants.ReportingConfig.SHOULD_ALLOW_ZERO_TALLIES)).thenReturn(true);
166159

167160
SQLiteDatabase database = Mockito.mock(SQLiteDatabase.class);
168161
Map<String, IndicatorQuery> indicatorQueries = new HashMap<>();

sample/build.gradle

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ android {
6464
exclude 'META-INF/LICENSE.md'
6565
exclude 'META-INF/NOTICE.md'
6666
exclude 'META-INF/LGPL2.1'
67+
exclude 'META-INF/INDEX.LIST'
6768
exclude 'LICENSE.txt'
6869
}
6970

@@ -88,7 +89,7 @@ dependencies {
8889
exclude group: 'org.apache.httpcomponents', module: 'httpmime'
8990
exclude group: 'com.ibm.fhir', module: 'fhir-model'
9091
}
91-
compileOnly 'com.ibm.fhir:fhir-model:4.2.3'
92+
compileOnly 'com.ibm.fhir:fhir-model:4.7.0'
9293

9394
implementation project(":opensrp-reporting")
9495

0 commit comments

Comments
 (0)