File tree Expand file tree Collapse file tree
java/src/test/java/com/alibaba/graphar/graphinfo
spark/src/test/scala/com/alibaba/graphar Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ GAR_NAMESPACE::Status GetTestResourceRoot(std::string* out) {
3737 " Test resources not found, set GAR_TEST_DATA to <repo root>/testing" );
3838 }
3939 // FIXME(@acezen): This is a hack to get around the fact that the testing
40- *out = std::string (c_root) + " /new " ;
40+ *out = std::string (c_root);
4141 return GAR_NAMESPACE::Status::OK ();
4242}
4343
Original file line number Diff line number Diff line change 5454#define DASSERT (x )
5555#endif
5656
57- // FIXME(@acezen): This is a hack to get around the fact that the testing
5857static const std::string TEST_DATA_DIR = // NOLINT
5958 std::filesystem::path (__FILE__)
6059 .parent_path()
6160 .parent_path()
6261 .parent_path()
6362 .parent_path()
6463 .string() +
65- "/testing/new ";
64+ "/testing";
6665
6766#endif // CPP_EXAMPLES_CONFIG_H_
Original file line number Diff line number Diff line change @@ -30,8 +30,7 @@ GAR_NAMESPACE::Status GetTestResourceRoot(std::string* out) {
3030 return GAR_NAMESPACE::Status::IOError (
3131 " Test resources not found, set GAR_TEST_DATA to <repo root>/testing" );
3232 }
33- // FIXME(@acezen): This is a hack to get around the fact that the testing
34- *out = std::string (c_root) + " /new" ;
33+ *out = std::string (c_root);
3534 return GAR_NAMESPACE::Status::OK ();
3635}
3736
Original file line number Diff line number Diff line change 2525import org .junit .Test ;
2626
2727public class GraphInfoTest {
28- public static final String root = System .getenv ("GAR_TEST_DATA" );
28+ public static final String root = System .getenv ("GAR_TEST_DATA" ) + "/java" ;
2929
3030 @ Test
3131 public void test1 () {
Original file line number Diff line number Diff line change 2626def test_transform (spark ):
2727 initialize (spark )
2828 source_path = (
29- GRAPHAR_TESTS_EXAMPLES .joinpath ("new/ ldbc_sample/parquet/ldbc_sample.graph.yml" )
29+ GRAPHAR_TESTS_EXAMPLES .joinpath ("ldbc_sample/parquet/ldbc_sample.graph.yml" )
3030 .absolute ()
3131 .__str__ ()
3232 )
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ class ComputeExampleSuite extends AnyFunSuite {
3131
3232 test(" run cc using graphx" ) {
3333 // read vertex DataFrame
34- val file_path = " gar-test/new/ ldbc_sample/parquet/"
34+ val file_path = " gar-test/ldbc_sample/parquet/"
3535 val prefix = getClass.getClassLoader.getResource(file_path).getPath
3636 val vertex_yaml = getClass.getClassLoader
3737 .getResource(file_path + " person.vertex.yml" )
Original file line number Diff line number Diff line change @@ -29,11 +29,11 @@ class GraphInfoSuite extends AnyFunSuite {
2929 test(" load graph info" ) {
3030 // read graph yaml
3131 val yaml_path = getClass.getClassLoader
32- .getResource(" gar-test/new/ ldbc_sample/csv/ldbc_sample.graph.yml" )
32+ .getResource(" gar-test/ldbc_sample/csv/ldbc_sample.graph.yml" )
3333 .getPath
3434 val prefix =
3535 getClass.getClassLoader
36- .getResource(" gar-test/new/ ldbc_sample/csv/" )
36+ .getResource(" gar-test/ldbc_sample/csv/" )
3737 .getPath
3838 val graph_info = GraphInfo .loadGraphInfo(yaml_path, spark)
3939
@@ -127,7 +127,7 @@ class GraphInfoSuite extends AnyFunSuite {
127127
128128 test(" load edge info" ) {
129129 val yaml_path = getClass.getClassLoader
130- .getResource(" gar-test/new/ ldbc_sample/csv/person_knows_person.edge.yml" )
130+ .getResource(" gar-test/ldbc_sample/csv/person_knows_person.edge.yml" )
131131 .getPath
132132 val edge_info = EdgeInfo .loadEdgeInfo(yaml_path, spark)
133133
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ class TestGraphReaderSuite extends AnyFunSuite {
3131 test(" read graphs by yaml paths" ) {
3232 // conduct reading
3333 val graph_path = getClass.getClassLoader
34- .getResource(" gar-test/new/ ldbc_sample/parquet/ldbc_sample.graph.yml" )
34+ .getResource(" gar-test/ldbc_sample/parquet/ldbc_sample.graph.yml" )
3535 .getPath
3636 val vertex_edge_df_pair = GraphReader .read(graph_path, spark)
3737 val vertex_dataframes = vertex_edge_df_pair._1
@@ -54,7 +54,7 @@ class TestGraphReaderSuite extends AnyFunSuite {
5454 test(" read graphs by graph infos" ) {
5555 // load graph info
5656 val path = getClass.getClassLoader
57- .getResource(" gar-test/new/ ldbc_sample/parquet/ldbc_sample.graph.yml" )
57+ .getResource(" gar-test/ldbc_sample/parquet/ldbc_sample.graph.yml" )
5858 .getPath
5959 val graph_info = GraphInfo .loadGraphInfo(path, spark)
6060
Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ class TestGraphTransformerSuite extends AnyFunSuite {
3232 test(" transform graphs by yaml paths" ) {
3333 // conduct transformation
3434 val source_path = getClass.getClassLoader
35- .getResource(" gar-test/new/ ldbc_sample/parquet/ldbc_sample.graph.yml" )
35+ .getResource(" gar-test/ldbc_sample/parquet/ldbc_sample.graph.yml" )
3636 .getPath
3737 val dest_path = getClass.getClassLoader
3838 .getResource(" gar-test/transformer/ldbc_sample.graph.yml" )
@@ -71,7 +71,7 @@ class TestGraphTransformerSuite extends AnyFunSuite {
7171 test(" transform graphs by graph infos" ) {
7272 // load source graph info
7373 val source_path = getClass.getClassLoader
74- .getResource(" gar-test/new/ ldbc_sample/parquet/ldbc_sample.graph.yml" )
74+ .getResource(" gar-test/ldbc_sample/parquet/ldbc_sample.graph.yml" )
7575 .getPath
7676 val source_graph_info = GraphInfo .loadGraphInfo(source_path, spark)
7777
Original file line number Diff line number Diff line change @@ -112,7 +112,7 @@ class ReaderSuite extends AnyFunSuite {
112112
113113 test(" read vertex chunks" ) {
114114 // construct the vertex information
115- val file_path = " gar-test/new/ ldbc_sample/parquet/"
115+ val file_path = " gar-test/ldbc_sample/parquet/"
116116 val prefix = getClass.getClassLoader.getResource(file_path).getPath
117117 val vertex_yaml = getClass.getClassLoader
118118 .getResource(file_path + " person.vertex.yml" )
@@ -210,7 +210,7 @@ class ReaderSuite extends AnyFunSuite {
210210
211211 test(" read edge chunks" ) {
212212 // construct the edge information
213- val file_path = " gar-test/new/ ldbc_sample/csv/"
213+ val file_path = " gar-test/ldbc_sample/csv/"
214214 val prefix = getClass.getClassLoader.getResource(file_path).getPath
215215 val edge_yaml = getClass.getClassLoader
216216 .getResource(file_path + " person_knows_person.edge.yml" )
You can’t perform that action at this time.
0 commit comments