import {browserHistory} from 'react-router';
import {render, screen} from 'sentry-test/reactTestingLibrary';
import {ProjectInstallPlatform} from 'sentry/views/projectInstall/platform';
describe('ProjectInstallPlatform', function () {
describe('render()', function () {
const baseProps = {
api: new MockApiClient(),
organization: TestStubs.Organization(),
project: TestStubs.Project(),
location: {query: {}},
};
it('should redirect to if no matching platform', function () {
const props = {
...baseProps,
params: {
projectId: baseProps.project.slug,
platform: 'other',
},
};
MockApiClient.addMockResponse({
url: '/projects/org-slug/project-slug/docs/other/',
body: {},
});
MockApiClient.addMockResponse({
method: 'GET',
url: '/organizations/org-slug/projects/',
body: [baseProps.project],
});
render(