Skip to content

Commit

Permalink
Fix RecipeValidationTest
Browse files Browse the repository at this point in the history
  • Loading branch information
jkschneider committed Aug 15, 2024
1 parent c4baa1c commit 26f62e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,9 @@ CategoryTree<G> findOrAddCategory(G group, CategoryDescriptor category) {
}

void addRecipe(G group, RecipeDescriptor recipe) {
if (recipe.getName() == null) {
throw new IllegalArgumentException("Expected recipe to have a name " + recipe.getSource());
}
if (!recipe.getName().contains(".")) {
throw new IllegalArgumentException("Expected recipe with name '" + recipe.getName() + "' to have " +
"a package, but it did not.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public static class JSpecifyAnnotatedRecipeOptions extends Recipe {
@Option(displayName = "An optional field",
description = "Something that can be null.")
@Nullable
String name;
String optionalField;

@Override
public String getDisplayName() {
Expand Down

0 comments on commit 26f62e2

Please sign in to comment.