Skip to content

Commit

Permalink
Compose Metadata Analyzer: Refactor to support V2
Browse files Browse the repository at this point in the history
Signed-off-by: Valentijn Scholten <[email protected]>
  • Loading branch information
valentijnscholten committed Dec 23, 2024
1 parent b73448d commit 706ce01
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ private MetaModel analyzePackageVersions(final MetaModel meta, Component compone
try {
meta.setPublishedTimestamp(dateFormat.parse(published));
} catch (Exception e) {
LOGGER.warn("An error occurred while parsing upload time", e);
LOGGER.warn("An error occurred while parsing time", e);
}
} else {
//TODO some repositories like packages.drupal.org include a 'dateStamp' field, example 1700068743
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,7 @@ public void testAnalyzerIncludesAndRepoPath() throws Exception {
MetaModel metaModel = analyzer.analyze(component);

Assert.assertEquals("2.3.8", metaModel.getLatestVersion());
// Timestamps are in invalid format for this repo
Assert.assertNull(metaModel.getPublishedTimestamp());

mockClient.verify(
Expand Down

0 comments on commit 706ce01

Please sign in to comment.