test: run tests on Mastodon v4 (#2256)

pull/2289/head
Nolan Lawson 2022-12-02 15:09:58 -08:00 zatwierdzone przez GitHub
rodzic 30b00667f2
commit 6d6eb59f41
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
7 zmienionych plików z 756 dodań i 52 usunięć

Wyświetl plik

@ -4,7 +4,7 @@ on:
branches: [ master ]
jobs:
test:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
services:
postgres:
image: postgres:12.2
@ -28,7 +28,7 @@ jobs:
node-version: '14'
- uses: ruby/setup-ruby@v1
with:
ruby-version: '3.0.3'
ruby-version: '3.0.4'
- name: Cache Mastodon bundler
uses: actions/cache@v3
with:

Wyświetl plik

@ -4,7 +4,7 @@ on:
branches: [ master ]
jobs:
test:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
services:
postgres:
image: postgres:12.2
@ -28,7 +28,7 @@ jobs:
node-version: '14'
- uses: ruby/setup-ruby@v1
with:
ruby-version: '3.0.3'
ruby-version: '3.0.4'
- name: Cache Mastodon bundler
uses: actions/cache@v3
with:

Wyświetl plik

@ -19,9 +19,9 @@ BIND=0.0.0.0
`
export const GIT_URL = 'https://github.com/tootsuite/mastodon.git'
export const GIT_TAG = 'v3.5.3'
export const GIT_TAG = 'v4.0.2'
export const RUBY_VERSION = '3.0.3'
export const RUBY_VERSION = '3.0.4'
const __dirname = path.dirname(new URL(import.meta.url).pathname)
export const mastodonDir = path.join(__dirname, '../mastodon')

Plik diff jest za duży Load Diff

Plik binarny nie jest wyświetlany.

Wyświetl plik

@ -37,10 +37,10 @@ test('External links, hashtags, and mentions have correct attributes', async t =
.expect(nthAnchor(3).getAttribute('href')).eql('/tags/tag')
.expect(nthAnchor(3).hasAttribute('rel')).notOk()
.expect(nthAnchor(3).hasAttribute('target')).notOk()
.expect(nthAnchor(4).getAttribute('href')).eql('/tags/anotherTag')
.expect(nthAnchor(4).getAttribute('href')).eql('/tags/anothertag')
.expect(nthAnchor(4).hasAttribute('rel')).notOk()
.expect(nthAnchor(4).hasAttribute('target')).notOk()
.expect(nthAnchor(5).getAttribute('href')).eql('/tags/yetAnotherTag')
.expect(nthAnchor(5).getAttribute('href')).eql('/tags/yetanothertag')
.expect(nthAnchor(5).hasAttribute('rel')).notOk()
.expect(nthAnchor(5).hasAttribute('target')).notOk()
.expect(nthAnchor(6).getAttribute('href')).eql('http://example.com')

Wyświetl plik

@ -38,7 +38,8 @@ const addFilter = async (t, phrase, tweak) => {
.expect(modalDialog.exists).notOk()
}
test('Can filter basic words', async t => {
// TODO: test broken by Mastodon v4 bug https://github.com/mastodon/mastodon/issues/21965
test.skip('Can filter basic words', async t => {
await postAs('admin', 'do not filter me!')
await postAs('admin', 'filterMeOut okay!')
await postAs('admin', 'filterMeOutTooEvenThoughItIsOneBigWord!')