Skip to content

Conversation

@bchocho
Copy link
Contributor

@bchocho bchocho commented Sep 2, 2016

What changes were proposed in this pull request?

Add unit test for changes made in PR #14515. It makes sure that a newly created table has the same number of columns in table and partition metadata. This test fails before the changes introduced in #14515.

How was this patch tested?

Run new unit test.

@cloud-fan
Copy link
Contributor

ok to test

test("SPARK-16926: number of table and partition columns match for new partitioned table") {
val view = "src"
withTempView(view) {
spark.range(1, 5).createOrReplaceTempView(view)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: we should alway use createTempView in test, to make sure the view we created is what we want, rather than some existing view.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My understanding is that createOrReplaceTempView should ensure the same thing because any existing view would be replaced. I'm I missing something?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh sorry I read the code wrong...

@cloud-fan
Copy link
Contributor

LGTM

@SparkQA
Copy link

SparkQA commented Sep 2, 2016

Test build #64822 has finished for PR 14930 at commit 7ac4d63.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@cloud-fan
Copy link
Contributor

thanks, merging to master!

@asfgit asfgit closed this in f2d6e2e Sep 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants