forked from datahub-project/datahub
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'datahub-project:master' into master
- Loading branch information
Showing
13 changed files
with
877 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
...ore/src/test/java/com/linkedin/datahub/graphql/types/entitytype/EntityTypeMapperTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package com.linkedin.datahub.graphql.types.entitytype; | ||
|
||
import static org.testng.Assert.*; | ||
|
||
import com.linkedin.datahub.graphql.generated.EntityType; | ||
import com.linkedin.metadata.Constants; | ||
import org.testng.annotations.Test; | ||
|
||
public class EntityTypeMapperTest { | ||
|
||
@Test | ||
public void testGetType() throws Exception { | ||
assertEquals(EntityTypeMapper.getType(Constants.DATASET_ENTITY_NAME), EntityType.DATASET); | ||
} | ||
|
||
@Test | ||
public void testGetName() throws Exception { | ||
assertEquals(EntityTypeMapper.getName(EntityType.DATASET), Constants.DATASET_ENTITY_NAME); | ||
} | ||
} |
30 changes: 30 additions & 0 deletions
30
.../src/test/java/com/linkedin/datahub/graphql/types/entitytype/EntityTypeUrnMapperTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package com.linkedin.datahub.graphql.types.entitytype; | ||
|
||
import static org.testng.Assert.*; | ||
|
||
import com.linkedin.datahub.graphql.generated.EntityType; | ||
import com.linkedin.metadata.Constants; | ||
import org.testng.annotations.Test; | ||
|
||
public class EntityTypeUrnMapperTest { | ||
|
||
@Test | ||
public void testGetName() throws Exception { | ||
assertEquals( | ||
EntityTypeUrnMapper.getName("urn:li:entityType:datahub.dataset"), | ||
Constants.DATASET_ENTITY_NAME); | ||
} | ||
|
||
@Test | ||
public void testGetEntityType() throws Exception { | ||
assertEquals( | ||
EntityTypeUrnMapper.getEntityType("urn:li:entityType:datahub.dataset"), EntityType.DATASET); | ||
} | ||
|
||
@Test | ||
public void testGetEntityTypeUrn() throws Exception { | ||
assertEquals( | ||
EntityTypeUrnMapper.getEntityTypeUrn(Constants.DATASET_ENTITY_NAME), | ||
"urn:li:entityType:datahub.dataset"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.