Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f10dac3

Browse files
committed
Format some tests
1 parent b62b8c8 commit f10dac3

2 files changed

Lines changed: 25 additions & 25 deletions

File tree

java/ql/test/experimental/query-tests/security/CWE-089/src/main/MybatisSqlInjectionService.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -58,18 +58,18 @@ public List<Test> good1(Integer id) {
5858

5959
// using providers
6060
public String badSelect(String input) {
61-
return sqlInjectionMapper.badSelect(input);
62-
}
61+
return sqlInjectionMapper.badSelect(input);
62+
}
6363

6464
public void badDelete(String input) {
65-
sqlInjectionMapper.badDelete(input);
66-
}
65+
sqlInjectionMapper.badDelete(input);
66+
}
6767

6868
public void badUpdate(String input) {
69-
sqlInjectionMapper.badUpdate(input);
70-
}
69+
sqlInjectionMapper.badUpdate(input);
70+
}
7171

7272
public void badInsert(String input) {
73-
sqlInjectionMapper.badInsert(input);
74-
}
73+
sqlInjectionMapper.badInsert(input);
74+
}
7575
}

java/ql/test/experimental/query-tests/security/CWE-089/src/main/SqlInjectionMapper.java

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -42,21 +42,21 @@ public interface SqlInjectionMapper {
4242
)
4343
String badSelect(String input);
4444

45-
@DeleteProvider(
46-
type = MyBatisProvider.class,
47-
method = "badDelete"
48-
)
49-
void badDelete(String input);
50-
51-
@UpdateProvider(
52-
type = MyBatisProvider.class,
53-
method = "badUpdate"
54-
)
55-
void badUpdate(String input);
56-
57-
@InsertProvider(
58-
type = MyBatisProvider.class,
59-
method = "badInsert"
60-
)
61-
void badInsert(String input);
45+
@DeleteProvider(
46+
type = MyBatisProvider.class,
47+
method = "badDelete"
48+
)
49+
void badDelete(String input);
50+
51+
@UpdateProvider(
52+
type = MyBatisProvider.class,
53+
method = "badUpdate"
54+
)
55+
void badUpdate(String input);
56+
57+
@InsertProvider(
58+
type = MyBatisProvider.class,
59+
method = "badInsert"
60+
)
61+
void badInsert(String input);
6262
}

0 commit comments

Comments
 (0)