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

Springboot upgrade to 3.0.2 and also added github actions #62

Merged
merged 1 commit into from
Aug 31, 2023

Conversation

SoLetsDev
Copy link
Contributor

No description provided.

@github-advanced-security
Copy link

This pull request sets up GitHub code scanning for this repository. Once the scans have completed and the checks have passed, the analysis results for this pull request branch will appear on this overview. Once you merge this pull request, the 'Security' tab will show more code scanning analysis results (for example, for the default branch). Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results. For more information about GitHub code scanning, check out the documentation.

@sonarcloud
Copy link

sonarcloud bot commented Aug 31, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

88.9% 88.9% Coverage
0.0% 0.0% Duplication

@@ -15,7 +15,6 @@
public class StudentProfileStatusCodeEntity {

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I needed to remove this because it was causing junit to fail. The h2 database was not able to process this annotation and the table never got created. It was something along the lines of varchar(255) not handled.

I see in genderCodesEntity that they do not need a generated value.

this.entityManager.persist(this.document);
this.entityManager.flush();
//document = this.repository.save(document);
this.entityManager.clear();
Copy link
Contributor Author

@SoLetsDev SoLetsDev Aug 31, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I needed to rework this test since @dataJpaTests threw errors in the new springboot upgrade. Fix was to change the annotation to

@SpringBootTest(classes = {StudentProfileApiResourceApplication.class})
@activeprofiles("test")

however this meant that entityManager could no longer be autowired because it could not find a bean. So my fix was to save the test data to the repository directly.

rather than use entityManager.

@arcshiftsolutions arcshiftsolutions merged commit a57a552 into master Aug 31, 2023
5 checks passed
@arcshiftsolutions arcshiftsolutions deleted the feature/upgrade branch August 31, 2023 22:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants