diff --git a/hcatalog/src/test/e2e/templeton/inpdir/hcatloadstore.pig b/hcatalog/src/test/e2e/templeton/inpdir/hcatloadstore.pig index e69de29..a9bf7d6 100644 --- a/hcatalog/src/test/e2e/templeton/inpdir/hcatloadstore.pig +++ b/hcatalog/src/test/e2e/templeton/inpdir/hcatloadstore.pig @@ -0,0 +1,21 @@ +-- Licensed to the Apache Software Foundation (ASF) under one +-- or more contributor license agreements. See the NOTICE file +-- distributed with this work for additional information +-- regarding copyright ownership. The ASF licenses this file +-- to you under the Apache License, Version 2.0 (the +-- "License"); you may not use this file except in compliance +-- with the License. You may obtain a copy of the License at +-- +-- http://www.apache.org/licenses/LICENSE-2.0 +-- +-- Unless required by applicable law or agreed to in writing, +-- software distributed under the License is distributed on an +-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +-- KIND, either express or implied. See the License for the +-- specific language governing permissions and limitations +-- under the License. + +l = load '$INPDIR/nums.txt' as (i:int, j:int); +store l into 'hcattest_pig' using org.apache.hcatalog.pig.HCatStorer(); +s = load 'hcattest_pig' using org.apache.hcatalog.pig.HCatLoader(); +store s into '$OUTDIR/loadstore.out'; diff --git a/hcatalog/src/test/e2e/templeton/tests/jobsubmission.conf b/hcatalog/src/test/e2e/templeton/tests/jobsubmission.conf index b14c991..f394731 100644 --- a/hcatalog/src/test/e2e/templeton/tests/jobsubmission.conf +++ b/hcatalog/src/test/e2e/templeton/tests/jobsubmission.conf @@ -241,6 +241,28 @@ $cfg = }, + { + 'num' => 9, + 'setup' => [ + { + 'method' => 'POST', + 'url' => ':TEMPLETON_URL:/templeton/v1/ddl', + 'status_code' => 200, + 'post_options' => ['user.name=:UNAME:','exec=drop table if exists hcattest_pig; create table hcattest_pig(i int, j int) STORED AS textfile;'], + 'json_field_substr_match' => {'stderr' => 'OK'} + } + ], + 'method' => 'POST', + 'url' => ':TEMPLETON_URL:/templeton/v1/pig', + 'post_options' => ['user.name=:UNAME:', 'arg=-useHCatalog', 'arg=-p', 'arg=INPDIR=:INPDIR_HDFS:', 'arg=-p', 'arg= OUTDIR=:OUTDIR:', 'file=:INPDIR_HDFS:/hcatloadstore.pig'], + 'json_field_substr_match' => { 'id' => '\d+'}, + 'status_code' => 200, + 'check_job_created' => 1, + 'check_job_complete' => 'SUCCESS', + 'check_job_exit_value' => 0, + 'check_call_back' => 1, + + }, #test 9 #TODO jython test