Skip to content

🤖 Auto-generated changes for issue #1 #2

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

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 17 additions & 9 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,21 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.0.4.RELEASE</version>
<version>2.7.14</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<java.version>1.8</java.version>
<java.version>17</java.version>
<tomcat.port>9081</tomcat.port>
<tomcat.ip>127.0.0.1</tomcat.ip>
<file>readme</file>
<lombok.version>1.18.10</lombok.version>
<lombok.version>1.18.30</lombok.version>
<spring-security-oauth2.version>2.5.2.RELEASE</spring-security-oauth2.version>
<jackson-databind.version>2.15.2</jackson-databind.version>

</properties>

<dependencies>
Expand All @@ -46,6 +49,11 @@
<artifactId>spring-boot-starter-web</artifactId>
</dependency>

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-validation</artifactId>
</dependency>

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
Expand All @@ -64,18 +72,18 @@
<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-jwt</artifactId>
<version>1.0.7.RELEASE</version>
<version>1.1.1.RELEASE</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.springframework.security.oauth/spring-security-oauth2 -->
<dependency>
<groupId>org.springframework.security.oauth</groupId>
<artifactId>spring-security-oauth2</artifactId>
<version>2.1.0.RELEASE</version>
<version>${spring-security-oauth2.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.9.10.8</version>
<version>${jackson-databind.version}</version>
</dependency>

<dependency>
Expand Down Expand Up @@ -144,8 +152,8 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
<source>17</source>
<target>17</target>
<annotationProcessorPaths>
<path>
<groupId>org.projectlombok</groupId>
Expand All @@ -158,4 +166,4 @@
</plugins>
</build>

</project>
</project>
21 changes: 8 additions & 13 deletions src/main/resources/sql-scripts/schema.sql
Original file line number Diff line number Diff line change
@@ -1,30 +1,25 @@
CREATE TABLE random_city (
id bigint(20) NOT NULL AUTO_INCREMENT,
name varchar(255) DEFAULT NULL,
PRIMARY KEY (id)
id IDENTITY NOT NULL PRIMARY KEY,
name varchar(255) DEFAULT NULL
);

CREATE TABLE app_role (
id bigint(20) NOT NULL AUTO_INCREMENT,
id IDENTITY NOT NULL PRIMARY KEY,
description varchar(255) DEFAULT NULL,
role_name varchar(255) DEFAULT NULL,
PRIMARY KEY (id)
role_name varchar(255) DEFAULT NULL
);


CREATE TABLE app_user (
id bigint(20) NOT NULL AUTO_INCREMENT,
id IDENTITY NOT NULL PRIMARY KEY,
first_name varchar(255) NOT NULL,
last_name varchar(255) NOT NULL,
password varchar(255) NOT NULL,
username varchar(255) NOT NULL,
PRIMARY KEY (id)
username varchar(255) NOT NULL
);


CREATE TABLE user_role (
user_id bigint(20) NOT NULL,
role_id bigint(20) NOT NULL,
user_id bigint NOT NULL,
role_id bigint NOT NULL,
CONSTRAINT FK859n2jvi8ivhui0rl0esws6o FOREIGN KEY (user_id) REFERENCES app_user (id),
CONSTRAINT FKa68196081fvovjhkek5m97n3y FOREIGN KEY (role_id) REFERENCES app_role (id)
);
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
package com.nouhoun.springboot.jwt.integration;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

@RunWith(SpringRunner.class)
@SpringBootTest
public class SpringbootJwtApplicationTests {
class SpringbootJwtApplicationTests {

@Test
public void contextLoads() {
void contextLoads() {
}

}
}