Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blueprint (jdl) fails during unit test #25385

Closed
1 task done
dwarakaprasad opened this issue Mar 1, 2024 · 0 comments · Fixed by #25386
Closed
1 task done

blueprint (jdl) fails during unit test #25385

dwarakaprasad opened this issue Mar 1, 2024 · 0 comments · Fixed by #25386

Comments

@dwarakaprasad
Copy link
Contributor

Overview of the issue

When creating a jdl blueprint, unit tests fails with the follwoing exception,

generators/jdl/generator.spec.mjs > SubGenerator jdl of basepack JHipster blueprint > run
Error: At least one jdl file is required.
 ❯ default.checkOptions node_modules/generator-jhipster/dist/generators/jdl/generator.mjs:85:27
 ❯ default.executeTask node_modules/yeoman-generator/dist/actions/lifecycle.js:244:26
 ❯ env.queueTask.once node_modules/yeoman-generator/dist/actions/lifecycle.js:218:56
 ❯ runLoop.add.once node_modules/yeoman-environment/dist/environment-base.js:384:23
 ❯ Immediate.<anonymous> node_modules/grouped-queue/lib/subqueue.js:48:34

 Test Files  1 failed (1)
      Tests   (1)
   Start at  22:27:43
   Duration  5.10s
Motivation for or Use Case
Reproduce the error
Related issues

None

Suggest a Fix

add

<%_ if (subGenerator === 'jdl') { _%>
          inline: 'application { }',
<%_ } _%>

to template

JHipster Version(s)

8.1.0

JHipster configuration
JHipster configuration, a .yo-rc.json file generated in the root folder
.yo-rc.json file
{
  "generator-jhipster": {
    "additionalSubGenerators": "",
    "baseName": "basepack",
    "cli": true,
    "entities": [],
    "generators": {
      "angular": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "app": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "ci-cd": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "client": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "common": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "cypress": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "gradle": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "jdl": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "languages": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": true,
        "written": true
      },
      "liquibase": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "maven": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      },
      "workspaces": {
        "command": true,
        "priorities": [
          "initializing",
          "prompting",
          "configuring",
          "composing",
          "loading",
          "preparing",
          "configuringEachEntity",
          "loadingEntities",
          "preparingEachEntity",
          "preparingEachEntityField",
          "preparingEachEntityRelationship",
          "postPreparingEachEntity",
          "default",
          "writing",
          "writingEntities",
          "postWriting",
          "postWritingEntities",
          "loadingTranslations",
          "install",
          "postInstall",
          "end"
        ],
        "sbs": false,
        "written": true
      }
    },
    "jhipsterVersion": "8.1.0",
    "localBlueprint": false,
    "sampleWritten": true,
    "skipCommitHook": true,
    "subGenerators": [
      "angular",
      "app",
      "ci-cd",
      "client",
      "common",
      "cypress",
      "gradle",
      "jdl",
      "languages",
      "liquibase",
      "maven",
      "workspaces"
    ]
  }
}
Environment and Tools

openjdk version "17.0.8" 2023-07-18
OpenJDK Runtime Environment Temurin-17.0.8+7 (build 17.0.8+7)
OpenJDK 64-Bit Server VM Temurin-17.0.8+7 (build 17.0.8+7, mixed mode, sharing)

git version 2.34.1

node: v18.19.0
npm: 10.2.3

Docker version 25.0.3, build 4debf41

JDL for the Entity configuration(s) entityName.json files generated in the .jhipster directory
JDL entity definitions

Entity configuration(s) entityName.json files generated in the .jhipster directory
Browsers and Operating System
  • Checking this box is mandatory (this is just to show you read everything)
mshima pushed a commit that referenced this issue Mar 1, 2024
* add inline jdl content to blueprint spec option

fixes #25385

* add jdl subgenerator to blueprints ci-cd
@deepu105 deepu105 added this to the 8.2.0 milestone Mar 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants