Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
penginn-net committed Jan 10, 2025
1 parent c7a9b5d commit 22625a5
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions packages/backend/test-federation/test/emoji.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ describe('Emoji', () => {

// @ts-expect-error anyで警告が出るため
const emojiId = (await bAdmin.client.request('admin/emoji/list-remote')).find( x => x.name === emoji.name).id;
let res = await fetch(`https://b.test/api/admin/emoji/copy`, {
const res = await fetch(`https://b.test/api/admin/emoji/copy`, {
method: 'POST',
body: JSON.stringify({
emojiId: emojiId,
Expand All @@ -210,7 +210,7 @@ describe('Emoji', () => {
credentials: 'omit',
cache: 'no-cache',
});
strictEqual((await res.json()).code, 'NOT_ALLOWED')
strictEqual((await res.json()).code, 'NOT_ALLOWED');
});
test('コピー拒否の絵文字をコピーできない(steal)', async () => {
const emoji = await addCustomEmoji('a.test', {
Expand All @@ -233,7 +233,7 @@ describe('Emoji', () => {
assert(noteInB.emojis != null);
assert(emoji.name in noteInB.emojis);
strictEqual(noteInB.emojis[emoji.name], emoji.url);
let res = await fetch(`https://b.test/api/admin/emoji/steal`, {
const res = await fetch(`https://b.test/api/admin/emoji/steal`, {
method: 'POST',
body: JSON.stringify({
name: emoji.name,
Expand All @@ -246,7 +246,7 @@ describe('Emoji', () => {
credentials: 'omit',
cache: 'no-cache',
});
strictEqual((await res.json()).code, 'NOT_ALLOWED')
strictEqual((await res.json()).code, 'NOT_ALLOWED');
});

test('コピー許可の絵文字をコピーできる(copy)', async () => {
Expand Down Expand Up @@ -356,7 +356,7 @@ describe('Emoji', () => {

// @ts-expect-error anyで警告が出るため
const emojiId = (await bAdmin.client.request('admin/emoji/list-remote')).find( x => x.name === emoji.name).id;
let res = await fetch(`https://b.test/api/admin/emoji/copy`, {
const res = await fetch(`https://b.test/api/admin/emoji/copy`, {
method: 'POST',
body: JSON.stringify({
emojiId: emojiId,
Expand All @@ -368,7 +368,7 @@ describe('Emoji', () => {
credentials: 'omit',
cache: 'no-cache',
});
strictEqual((await res.json()).code, 'SEE_USAGEINFOMATION_OR_LICENSE')
strictEqual((await res.json()).code, 'SEE_USAGEINFOMATION_OR_LICENSE');
});
test('条件付きの絵文字をコピーできない(steal)', async () => {
const emoji = await addCustomEmoji('a.test', {
Expand All @@ -391,7 +391,7 @@ describe('Emoji', () => {
assert(noteInB.emojis != null);
assert(emoji.name in noteInB.emojis);
strictEqual(noteInB.emojis[emoji.name], emoji.url);
let res = await fetch(`https://b.test/api/admin/emoji/steal`, {
const res = await fetch(`https://b.test/api/admin/emoji/steal`, {
method: 'POST',
body: JSON.stringify({
name: emoji.name,
Expand All @@ -404,8 +404,9 @@ describe('Emoji', () => {
credentials: 'omit',
cache: 'no-cache',
});
strictEqual((await res.json()).code, 'SEE_USAGEINFOMATION_OR_LICENSE')
strictEqual((await res.json()).code, 'SEE_USAGEINFOMATION_OR_LICENSE');
});

test('条件付きの絵文字をコピーできる(copy)', async () => {
const emoji = await addCustomEmoji('a.test', {
aliases: ['a', 'b', 'c'],
Expand Down Expand Up @@ -488,5 +489,4 @@ describe('Emoji', () => {
isBasedOn: 'isBasedOn',
}), JSON.stringify(res));
});

});

0 comments on commit 22625a5

Please sign in to comment.