mirror of
https://github.com/haiwen/seahub.git
synced 2025-08-28 11:41:18 +00:00
fix test
This commit is contained in:
parent
2000c9b792
commit
8c6ae8676e
@ -1,7 +1,7 @@
|
|||||||
import React, { Component } from 'react';
|
import React, { Component } from 'react';
|
||||||
import ReactDOM from 'react-dom';
|
import ReactDOM from 'react-dom';
|
||||||
import { Router, navigate } from '@reach/router';
|
import { Router, navigate } from '@reach/router';
|
||||||
import { siteRoot, canAddRepo } from './utils/constants';
|
import { siteRoot, canAddRepo, isDocs } from './utils/constants';
|
||||||
import { Utils } from './utils/utils';
|
import { Utils } from './utils/utils';
|
||||||
import SystemNotification from './components/system-notification';
|
import SystemNotification from './components/system-notification';
|
||||||
import SidePanel from './components/side-panel';
|
import SidePanel from './components/side-panel';
|
||||||
@ -61,7 +61,9 @@ class App extends Component {
|
|||||||
// get reviews
|
// get reviews
|
||||||
// TODO: need refactor later
|
// TODO: need refactor later
|
||||||
let href = window.location.href.split('/');
|
let href = window.location.href.split('/');
|
||||||
this.getDrafts();
|
if (isDocs) {
|
||||||
|
this.getDrafts();
|
||||||
|
}
|
||||||
this.setState({currentTab: href[href.length - 2]});
|
this.setState({currentTab: href[href.length - 2]});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -60,9 +60,7 @@ class WikisViewTest(BaseTestCase):
|
|||||||
assert len(Wiki.objects.all()) == 0
|
assert len(Wiki.objects.all()) == 0
|
||||||
|
|
||||||
resp = self.client.post(self.url, {
|
resp = self.client.post(self.url, {
|
||||||
'name': 'test wiki',
|
'repo_id': self.repo.id,
|
||||||
'repo_id': '',
|
|
||||||
'use_exist_repo': 'false',
|
|
||||||
})
|
})
|
||||||
self.assertEqual(200, resp.status_code)
|
self.assertEqual(200, resp.status_code)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user