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

Yavin Demo App Test are not passing #1726

Open
QubitPi opened this issue Jun 22, 2023 · 4 comments
Open

Yavin Demo App Test are not passing #1726

QubitPi opened this issue Jun 22, 2023 · 4 comments
Labels

Comments

@QubitPi
Copy link

QubitPi commented Jun 22, 2023

Describe the bug

We were trying to run test on a Yavin app but see tests were failing.

To Reproduce

  1. git clone [email protected]:yavin-dev/app.git
  2. cd app
  3. ./gradlew build

Expected behavior

All tests should pass

Screenshots

StaticAssetServingTest > graphiql_landing_page_test() PASSED

StaticAssetServingTest > ui_route_test() FAILED
    java.lang.NullPointerException at StaticAssetServingTest.kt:48

StaticAssetServingTest > api_landing_page_test() PASSED

StaticAssetServingTest > swagger_landing_page_test() PASSED

StaticAssetServingTest > landing_page_test() FAILED
    java.lang.NullPointerException at StaticAssetServingTest.kt:25

RoleTest > createDateTest() PASSED

RoleTest > roleEndpointTest() PASSED

DashboardTest > dashboard() PASSED

DashboardTest > wrongUser() PASSED

DashboardTest > permissions() PASSED

DashboardTest > dashboardWithWidgets() PASSED

DashboardTest > globalFilters() PASSED

DashboardWidgetTest > dashboardWidget() PASSED

DashboardWidgetTest > widgetSetAuthor() PASSED

DashboardWidgetTest > widgetUserPermission() PASSED

DemoDataSourceTest > simple_netflix_table_test() PASSED

BasicTest > basic_server_hello() PASSED

AsyncQueryTest > testAsyncQueryPermissions() PASSED

UserTest > userEndpointTest() PASSED

UserTest > createDateTest() PASSED

UserTest > userPermissions() PASSED

UserTest > reverseRelationships() PASSED

UserTest > favoriteReports() PASSED

UserTest > roles() PASSED

UserTest > editingDashboards() PASSED

UserTest > securityTest() PASSED

UserTest > favoriteDashboards() PASSED

CorsFilterTest > it can return cors headers() PASSED

CorsFilterTest > it rejects bad request methods() PASSED

ReportTest > userPermissions() PASSED

ReportTest > report() PASSED

ReportTest > wrongUser() PASSED

ReportTest > differentAuthorPermissions() PASSED

ReportTest > createDate() PASSED

ReportTest > testHaving() PASSED

ReportTest > reportSort() PASSED

RequestV2Test > dashboardsWithRequestV2() PASSED

RequestV2Test > reportWithRequestV2() PASSED

RequestV2Test > testHaving() PASSED

ServerGeneratedConfigTest > server_generated_config() PASSED

40 tests completed, 2 failed

> Task :ws:test FAILED

FAILURE: Build failed with an exception.

Desktop (please complete the following information):

  • OS: Mac
  • Version: yavin-dev/app master branch

Additional context

N/A

@QubitPi QubitPi added the bug label Jun 22, 2023
@kevinhinterlong
Copy link
Member

Could you tell us which version of Java you are using? I think our readme might be outdated and you may see those errors with java 8, but I just tried to reproduce this using java 11 and the tests passed

$ javac -version
javac 11.0.11

@QubitPi
Copy link
Author

QubitPi commented Jun 22, 2023

Hi @kevinhinterlong . Thanks for the prompt response. Our environments have Java 11 as well

javac -version
javac 11.0.16.1

One of the failed tests seems to be complaining about StaticAssetServingTest.kt:25

StaticAssetServingTest > landing_page_test() FAILED
    java.lang.NullPointerException at StaticAssetServingTest.kt:25

On that line, it is trying to load a file in resources/ui directory, which we didn't see on master branch

@kevinhinterlong
Copy link
Member

Hmm, it sounds like it's not building the ui subproject and copying the output over correctly. These are the files that it should build and copy over

# in the root 'app' dir
$ ls ui/build/resources/main/META-INF/resources/ui/
assets     fonts      img        index.html robots.txt testem.js  tests

You could also try running ./gradlew build -p ui directly to see if any errors occurred during the build

@QubitPi
Copy link
Author

QubitPi commented Nov 21, 2023

Thank you @kevinhinterlong for investigating! I'll definitely try it later today

(Sorry for the very late reply. :) )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants