mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-24 20:14:35 -04:00
Change api route to /api/private (#1189)
This commit is contained in:
parent
344304f329
commit
29d9d49f5a
20 changed files with 11 additions and 11 deletions
|
@ -31,7 +31,7 @@ describe('File upload', () => {
|
|||
beforeEach(() => {
|
||||
cy.intercept({
|
||||
method: 'POST',
|
||||
url: '/api/v2/media/upload'
|
||||
url: '/api/private/media/upload'
|
||||
}, {
|
||||
statusCode: 201,
|
||||
body: {
|
||||
|
@ -86,7 +86,7 @@ describe('File upload', () => {
|
|||
it('upload fails', () => {
|
||||
cy.intercept({
|
||||
method: 'POST',
|
||||
url: '/api/v2/media/upload'
|
||||
url: '/api/private/media/upload'
|
||||
}, {
|
||||
statusCode: 400
|
||||
})
|
||||
|
|
|
@ -26,7 +26,7 @@ describe('History', () => {
|
|||
describe('Pinning', () => {
|
||||
describe('working', () => {
|
||||
beforeEach(() => {
|
||||
cy.intercept('PUT', '/api/v2/history/features', (req) => {
|
||||
cy.intercept('PUT', '/api/private/history/features', (req) => {
|
||||
req.reply(200, req.body)
|
||||
})
|
||||
})
|
||||
|
@ -60,7 +60,7 @@ describe('History', () => {
|
|||
|
||||
describe('failing', () => {
|
||||
beforeEach(() => {
|
||||
cy.intercept('PUT', '/api/v2/history/features', {
|
||||
cy.intercept('PUT', '/api/private/history/features', {
|
||||
statusCode: 401
|
||||
})
|
||||
})
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
describe('profile page', () => {
|
||||
beforeEach(() => {
|
||||
cy.intercept({
|
||||
url: '/api/v2/tokens',
|
||||
url: '/api/private/tokens',
|
||||
method: 'GET'
|
||||
}, {
|
||||
body: [
|
||||
|
@ -18,7 +18,7 @@ describe('profile page', () => {
|
|||
]
|
||||
})
|
||||
cy.intercept({
|
||||
url: '/api/v2/tokens',
|
||||
url: '/api/private/tokens',
|
||||
method: 'POST'
|
||||
}, {
|
||||
body: {
|
||||
|
@ -28,7 +28,7 @@ describe('profile page', () => {
|
|||
}
|
||||
})
|
||||
cy.intercept({
|
||||
url: '/api/v2/tokens/1601991518',
|
||||
url: '/api/private/tokens/1601991518',
|
||||
method: 'DELETE'
|
||||
}, {
|
||||
body: []
|
||||
|
|
|
@ -83,7 +83,7 @@ describe('When logged-out ', () => {
|
|||
cy.get('[data-cy=sign-in-button]')
|
||||
.should('be.visible')
|
||||
// The absolute URL is used because it is defined as API base URL absolute.
|
||||
.should('have.attr', 'href', 'http://127.0.0.1:3001/api/v2/auth/saml')
|
||||
.should('have.attr', 'href', 'http://127.0.0.1:3001/api/private/auth/saml')
|
||||
})
|
||||
})
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue