Add account benchmarks
This commit is contained in:
parent
b4b76b72ff
commit
11ff88e44f
8 changed files with 60 additions and 0 deletions
30
tests/benchmarks/graphql/account/graphql-full-selection.js
Normal file
30
tests/benchmarks/graphql/account/graphql-full-selection.js
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
import http from 'k6/http';
|
||||||
|
export const options = {
|
||||||
|
vus: 20,
|
||||||
|
duration: '60s',
|
||||||
|
};
|
||||||
|
export default function () {
|
||||||
|
http.post('http://localhost/v1/graphql', JSON.stringify({
|
||||||
|
query: `query {
|
||||||
|
accountGet {
|
||||||
|
_id
|
||||||
|
_createdAt
|
||||||
|
_updatedAt
|
||||||
|
name
|
||||||
|
registration
|
||||||
|
status
|
||||||
|
passwordUpdate
|
||||||
|
email
|
||||||
|
phone
|
||||||
|
emailVerification
|
||||||
|
phoneVerification
|
||||||
|
}
|
||||||
|
}`
|
||||||
|
}), {
|
||||||
|
headers: {
|
||||||
|
'Content-Type': 'application/json',
|
||||||
|
'X-Appwrite-Project': 'test',
|
||||||
|
'Cookie': ''
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
16
tests/benchmarks/graphql/account/graphql-selection-set.js
Normal file
16
tests/benchmarks/graphql/account/graphql-selection-set.js
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
import http from 'k6/http';
|
||||||
|
export const options = {
|
||||||
|
vus: 20,
|
||||||
|
duration: '60s',
|
||||||
|
};
|
||||||
|
export default function () {
|
||||||
|
http.post('http://localhost/v1/graphql', JSON.stringify({
|
||||||
|
query: `query { accountGet { _id email } }`
|
||||||
|
}), {
|
||||||
|
headers: {
|
||||||
|
'Content-Type': 'application/json',
|
||||||
|
'X-Appwrite-Project': 'test',
|
||||||
|
'Cookie': ''
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
14
tests/benchmarks/graphql/account/rest.js
Normal file
14
tests/benchmarks/graphql/account/rest.js
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
import http from 'k6/http';
|
||||||
|
export const options = {
|
||||||
|
vus: 20,
|
||||||
|
duration: '60s',
|
||||||
|
};
|
||||||
|
export default function () {
|
||||||
|
http.get('http://localhost/v1/account', {
|
||||||
|
headers: {
|
||||||
|
'Content-Type': 'application/json',
|
||||||
|
'X-Appwrite-Project': 'test',
|
||||||
|
'Cookie': ''
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
Loading…
Reference in a new issue