HBASE-14588 Stop accessing test resources from within src folder (Andrew Wang)
This commit is contained in:
parent
2428c5f467
commit
a45cb72ef2
|
@ -43,8 +43,8 @@ public class TestReference {
|
|||
@Test
|
||||
public void testParsingWritableReference() throws IOException {
|
||||
// Read a Reference written w/ 0.94 out of the test data dir.
|
||||
final String datafile = System.getProperty("project.build.testSourceDirectory", "src/test") +
|
||||
File.separator + "data" + File.separator +
|
||||
final String datafile = System.getProperty("test.build.classes",
|
||||
"target/test-classes") + File.separator +
|
||||
"a6a6562b777440fd9c34885428f5cb61.21e75333ada3d5bafb34bb918f29576c";
|
||||
FileSystem fs = FileSystem.get(HTU.getConfiguration());
|
||||
Reference.read(fs, new Path(datafile));
|
||||
|
|
|
@ -116,9 +116,9 @@ public class TestRecoveredEdits {
|
|||
Path regionDir = region.getRegionDir(hbaseRootDir, hri);
|
||||
Path recoveredEditsDir = WALSplitter.getRegionDirRecoveredEditsDir(regionDir);
|
||||
// This is a little fragile getting this path to a file of 10M of edits.
|
||||
Path recoveredEditsFile = new Path(new Path(
|
||||
System.getProperty("project.build.testSourceDirectory", "src" + Path.SEPARATOR + "test"),
|
||||
"data"), "0000000000000016310");
|
||||
Path recoveredEditsFile = new Path(
|
||||
System.getProperty("test.build.classes", "target/test-classes"),
|
||||
"0000000000000016310");
|
||||
// Copy this file under the region's recovered.edits dir so it is replayed on reopen.
|
||||
Path destination = new Path(recoveredEditsDir, recoveredEditsFile.getName());
|
||||
fs.copyToLocalFile(recoveredEditsFile, destination);
|
||||
|
|
3
pom.xml
3
pom.xml
|
@ -575,6 +575,7 @@
|
|||
<redirectTestOutputToFile>${test.output.tofile}</redirectTestOutputToFile>
|
||||
<systemPropertyVariables>
|
||||
<jacoco-agent.destfile>target/jacoco.exec</jacoco-agent.destfile>
|
||||
<test.build.classes>${test.build.classes}</test.build.classes>
|
||||
</systemPropertyVariables>
|
||||
|
||||
<excludes>
|
||||
|
@ -1305,6 +1306,8 @@
|
|||
<hbase.skip-jacoco>true</hbase.skip-jacoco>
|
||||
<jacoco.version>0.7.5.201505241946</jacoco.version>
|
||||
<extra.enforcer.version>1.0-beta-3</extra.enforcer.version>
|
||||
<!-- Location of test resources -->
|
||||
<test.build.classes>${project.build.directory}/test-classes</test.build.classes>
|
||||
</properties>
|
||||
<!-- Sorted by groups of dependencies then groupId and artifactId -->
|
||||
<dependencyManagement>
|
||||
|
|
Loading…
Reference in New Issue