Skip to content

Commit

Permalink
Merge pull request #10 from element-hq/dbkr/changelog_repos
Browse files Browse the repository at this point in the history
Update repos for changelog fetching
  • Loading branch information
dbkr authored Sep 9, 2024
2 parents 6dd67b3 + e8c0b65 commit 461da98
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion src/components/views/dialogs/ChangelogDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ interface Commit {
};
}

const REPOS = ["vector-im/element-web", "matrix-org/matrix-react-sdk", "matrix-org/matrix-js-sdk"] as const;
const REPOS = ["element-hq/element-web", "element-hq/matrix-react-sdk", "matrix-org/matrix-js-sdk"] as const;

export default class ChangelogDialog extends React.Component<IProps, State> {
public constructor(props: IProps) {
Expand Down
28 changes: 14 additions & 14 deletions test/components/views/dialogs/ChangelogDialog-test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ import ChangelogDialog from "../../../../src/components/views/dialogs/ChangelogD

describe("<ChangelogDialog />", () => {
it("should fetch github proxy url for each repo with old and new version strings", async () => {
const webUrl = "https://riot.im/github/repos/vector-im/element-web/compare/oldsha1...newsha1";
const webUrl = "https://riot.im/github/repos/element-hq/element-web/compare/oldsha1...newsha1";
fetchMock.get(webUrl, {
url: "https://api.github.com/repos/vector-im/element-web/compare/master...develop",
html_url: "https://github.com/vector-im/element-web/compare/master...develop",
permalink_url: "https://github.com/vector-im/element-web/compare/vector-im:72ca95e...vector-im:8891698",
diff_url: "https://github.com/vector-im/element-web/compare/master...develop.diff",
patch_url: "https://github.com/vector-im/element-web/compare/master...develop.patch",
url: "https://api.github.com/repos/element-hq/element-web/compare/master...develop",
html_url: "https://github.com/element-hq/element-web/compare/master...develop",
permalink_url: "https://github.com/element-hq/element-web/compare/vector-im:72ca95e...vector-im:8891698",
diff_url: "https://github.com/element-hq/element-web/compare/master...develop.diff",
patch_url: "https://github.com/element-hq/element-web/compare/master...develop.patch",
base_commit: {},
merge_base_commit: {},
status: "ahead",
Expand All @@ -38,19 +38,19 @@ describe("<ChangelogDialog />", () => {
commits: [
{
sha: "commit-sha",
html_url: "https://api.github.com/repos/vector-im/element-web/commit/commit-sha",
html_url: "https://api.github.com/repos/element-hq/element-web/commit/commit-sha",
commit: { message: "This is the first commit message" },
},
],
files: [],
});
const reactUrl = "https://riot.im/github/repos/matrix-org/matrix-react-sdk/compare/oldsha2...newsha2";
const reactUrl = "https://riot.im/github/repos/element-hq/matrix-react-sdk/compare/oldsha2...newsha2";
fetchMock.get(reactUrl, {
url: "https://api.github.com/repos/matrix-org/matrix-react-sdk/compare/master...develop",
html_url: "https://github.com/matrix-org/matrix-react-sdk/compare/master...develop",
permalink_url: "https://github.com/matrix-org/matrix-react-sdk/compare/matrix-org:cdb00...matrix-org:4a926",
diff_url: "https://github.com/matrix-org/matrix-react-sdk/compare/master...develop.diff",
patch_url: "https://github.com/matrix-org/matrix-react-sdk/compare/master...develop.patch",
url: "https://api.github.com/repos/element-hq/matrix-react-sdk/compare/master...develop",
html_url: "https://github.com/element-hq/matrix-react-sdk/compare/master...develop",
permalink_url: "https://github.com/element-hq/matrix-react-sdk/compare/matrix-org:cdb00...matrix-org:4a926",
diff_url: "https://github.com/element-hq/matrix-react-sdk/compare/master...develop.diff",
patch_url: "https://github.com/element-hq/matrix-react-sdk/compare/master...develop.patch",
base_commit: {},
merge_base_commit: {},
status: "ahead",
Expand All @@ -60,7 +60,7 @@ describe("<ChangelogDialog />", () => {
commits: [
{
sha: "commit-sha0",
html_url: "https://api.github.com/repos/matrix-org/matrix-react-sdk/commit/commit-sha",
html_url: "https://api.github.com/repos/element-hq/matrix-react-sdk/commit/commit-sha",
commit: { message: "This is a commit message" },
},
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@ exports[`<ChangelogDialog /> should fetch github proxy url for each repo with ol
<h2
class="mx_Heading_h4"
>
vector-im/element-web
element-hq/element-web
</h2>
<ul>
<li
class="mx_ChangelogDialog_li"
>
<a
href="https://api.github.com/repos/vector-im/element-web/commit/commit-sha"
href="https://api.github.com/repos/element-hq/element-web/commit/commit-sha"
rel="noreferrer noopener"
target="_blank"
>
Expand All @@ -55,14 +55,14 @@ exports[`<ChangelogDialog /> should fetch github proxy url for each repo with ol
<h2
class="mx_Heading_h4"
>
matrix-org/matrix-react-sdk
element-hq/matrix-react-sdk
</h2>
<ul>
<li
class="mx_ChangelogDialog_li"
>
<a
href="https://api.github.com/repos/matrix-org/matrix-react-sdk/commit/commit-sha"
href="https://api.github.com/repos/element-hq/matrix-react-sdk/commit/commit-sha"
rel="noreferrer noopener"
target="_blank"
>
Expand Down

0 comments on commit 461da98

Please sign in to comment.