jhipster / generator-jhipster-react-native

A React Native blueprint for JHipster
https://jhipster-sample-app-react-native.vercel.app/
Apache License 2.0
265 stars 54 forks source link

Add E2E Tests for Reactive and NPM v7 #253

Closed ruddell closed 2 years ago

ruddell commented 3 years ago

Describe the bug

We need to test the following:

mshima commented 2 years ago

I will implement cypress.

mraible commented 2 years ago

Everything seems to be working now with npm 7.

mshima commented 2 years ago

E2E here was not cypress. 😆 I tried to take a look to cleanup this blueprint but is quite complicated. I will try to sync with ionic when I have time. If this issue is fixed few free to close.

mraible commented 2 years ago

I'll test with WebFlux and make sure it works before closing.

mraible commented 2 years ago

I tested with a WebFlux backend and npm run test:e2e passes just fine, so I'll close this issue.

mraible commented 2 years ago

@mshima I did notice the following and I'm unsure if it's my .yo-rc.json or a bug in JHipster. If I create a .yo-rc.json file with the following contents and create an app with the main branch, it fails to compile when I start it with ./mvnw.

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.10.1:testCompile (default-testCompile) on project flickr-2: Compilation failure: Compilation failure:
[ERROR] /Users/mraible/Downloads/postg/src/test/java/com/auth0/flickr2/config/PostgreSqlTestContainer.java:[7,37] cannot find symbol
[ERROR]   symbol:   class PostgreSQLContainer
[ERROR]   location: package org.testcontainers.containers
[ERROR] /Users/mraible/Downloads/postg/src/test/java/com/auth0/flickr2/config/PostgreSqlTestContainer.java:[14,13] cannot find symbol
[ERROR]   symbol:   class PostgreSQLContainer
[ERROR]   location: class com.auth0.flickr2.config.PostgreSqlTestContainer
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.

If I start it with ./mvnw -Pprod, it works fine. Here's my .yo-rc.json:

{
  "generator-jhipster": {
    "applicationType": "monolith",
    "authenticationType": "oauth2",
    "baseName": "flickr2",
    "blueprints": [],
    "buildTool": "maven",
    "cacheProvider": "no",
    "clientFramework": "react",
    "clientPackageManager": "npm",
    "clientTheme": "united",
    "clientThemeVariant": "dark",
    "creationTimestamp": 1634022348068,
    "databaseType": "sql",
    "devDatabaseType": "h2Disk",
    "devServerPort": 9060,
    "dtoSuffix": "DTO",
    "enableGradleEnterprise": false,
    "enableHibernateCache": false,
    "enableSwaggerCodegen": false,
    "enableTranslation": true,
    "entities": ["Album", "Photo", "Tag"],
    "entitySuffix": "",
    "herokuAppName": "flickr-2",
    "herokuDeployType": "git",
    "herokuJavaVersion": "11",
    "jhiPrefix": "jhi",
    "jhipsterVersion": "7.9.2",
    "languages": ["en", "pt-br"],
    "lastLiquibaseTimestamp": 1634025089000,
    "messageBroker": false,
    "monorepository": true,
    "nativeLanguage": "en",
    "otherModules": [],
    "packageName": "com.auth0.flickr2",
    "pages": [],
    "prodDatabaseType": "postgresql",
    "reactive": true,
    "searchEngine": false,
    "serverPort": "8080",
    "serverSideOptions": [],
    "serviceDiscoveryType": "no",
    "skipCheckLengthOfIdentifier": false,
    "skipClient": false,
    "skipCommitHook": true,
    "skipFakeData": false,
    "skipServer": false,
    "skipUserManagement": true,
    "testFrameworks": ["cypress"],
    "useOkta": false,
    "websocket": false,
    "withAdminUi": true
  }
}
mshima commented 2 years ago

@mraible maybe it’s related with the ide. I am having this problem from time to time with vscode. vscode is building the application ignoring profiles. I need to drop target folder when this happens. I will give a try probably tomorrow.

mraible commented 2 years ago

I was just using the command line, no IDE.

mshima commented 2 years ago

Let me check now

mshima commented 2 years ago

Yep, looks a bug.

mraible commented 2 years ago

@DanielFran https://opencollective.com/generator-jhipster/expenses/92827

pascalgrimaud commented 2 years ago

@mraible : approved