Skip to content

Conversation

bklager
Copy link
Collaborator

@bklager bklager commented Jun 13, 2018

No description provided.

@coveralls
Copy link

coveralls commented Jun 13, 2018

Pull Request Test Coverage Report for Build 13

  • 23 of 23 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+7.5%) to 100.0%

Totals Coverage Status
Change from base Build 10: 7.5%
Covered Lines: 43
Relevant Lines: 43

💛 - Coveralls

const groupId = node.groupId ? node.groupId[0] : '';
const artifactId = node.artifactId ? node.artifactId[0] : '';
const version = node.version ? node.version[0] : '';
const groupId = node.groupId ? node.groupId[0] : (node.parent ? getCoordinatesFromNode(node.parent[0]).groupId : undefined );
Copy link
Collaborator

Choose a reason for hiding this comment

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

Actually, based on https://maven.apache.org/guides/introduction/introduction-to-the-pom.html#Project_Inheritance , it looks like this works for the version as well, so let's check and make sure that we inherit version as well.

There's an interesting caveat to this that because it only works in situations where there is a parent at the same level meaning that parent elements and dependency elements are safe. We might want to add a comment here to indicate that for parent or dependencies, the parent check won't matter because it's not possible.

updatePolicy,
checksumPolicy
};

Copy link
Collaborator

Choose a reason for hiding this comment

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

minor: remove unnecessary blank line

<id>Target</id>
</repository>
</repositories>

Copy link
Collaborator

Choose a reason for hiding this comment

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

minor: remove unnecessary blank lines here

};
};

const getStatusFromRepo = (release) => {
Copy link
Collaborator

Choose a reason for hiding this comment

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

These elements are actually considered a "RepositoryPolicy" based on the type specified in the xsd.

Let's go ahead and update our naming to be consistent with that.

<xs:element minOccurs="0" name="releases" type="RepositoryPolicy">
  <xs:annotation>
    <xs:documentation source="version">4.0.0+</xs:documentation>
    <xs:documentation source="description">
        How to handle downloading of releases from this repository.
    </xs:documentation>
  </xs:annotation>
</xs:element>

</snapshots>
</repository>
</repositories>

Copy link
Collaborator

Choose a reason for hiding this comment

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

minor: remove unnecessary blank line

.then((pomContent) => {
assert(pomContent.repositories.length === 0);
});

Copy link
Collaborator

Choose a reason for hiding this comment

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

minor: remove unnecessary line.

<snapshots>
<enabled>let</enabled>
<updatePolicy>you</updatePolicy>
<checksumPolicy>down</checksumPolicy>
Copy link
Collaborator

Choose a reason for hiding this comment

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

Well played 💯

assert.equal(emptyRSrepository.snapshots.enabled, undefined);
assert.equal(emptyRSrepository.snapshots.updatePolicy, undefined);
assert.equal(emptyRSrepository.snapshots.checksumPolicy, undefined);

Copy link
Collaborator

Choose a reason for hiding this comment

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

minor: remove


});
});

Copy link
Collaborator

Choose a reason for hiding this comment

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

minor: remove

repository = pomContent.repositories[2];
assert.equal(repository.id, 'Target');
assert.equal(repository.url, undefined);

Copy link
Collaborator

Choose a reason for hiding this comment

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

minor: remove

@singletoncoding singletoncoding merged commit 103e0f9 into Singleton06:master Jun 14, 2018
@singletoncoding singletoncoding added the enhancement New feature or request label Jun 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants