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