### Copy Example Test Plan Source: https://feditest.org/quickstart/fediverse-developer/fediverse-mastodon-cloud Copy a suitable Test Plan as a starting point for your configuration. This example uses a fediverse follow manual SaaS plan. ```bash % cp examples/testplans/fediverse-follow-manual-saas.json myapp-follow-mastodon-ubos-ec2.json ``` -------------------------------- ### Install FediTest Framework Source: https://feditest.org/blog/2024-04-09-earliest-access Build and install the FediTest framework within a virtual Python environment. ```bash % cd feditest % python -mvenv venv % venv/bin/pip install . ``` -------------------------------- ### Install FediTest Source: https://feditest.org/quickstart/evaluate Installs the FediTest package using pacman. This is a prerequisite for running any FediTest commands. ```bash $ sudo pacman -S feditest ``` -------------------------------- ### Get FediTest Help Source: https://feditest.org/blog/2024-04-09-earliest-access Display available sub-commands and flags for the FediTest CLI. ```bash % ../feditest/venv/bin/feditest --help ``` -------------------------------- ### Deploy Mastodon with UBOS Gears Source: https://feditest.org/faq/feditest/role-of-ubos Use `ubos-admin deploy` to install and configure complex applications like Mastodon, including web server setup, TLS, database provisioning, and daemon startup. ```bash ubos-admin deploy ``` -------------------------------- ### FediTest Node Configuration with Parameters Source: https://feditest.org/reference/howtos/avoid-terminal-input An example of a FediTest node configuration file after saving interactive input, including hostname, app, and account details. ```json { "nodedriver" : "FediverseSaasNodeDriver", "parameters" : { "hostname" : "mastodon.example", "app" : "Mastodon" }, "accounts" : [ { "role" : null, "account_userid" : "joe" } ], "non_existing_accounts" : [ { "role" : null, "not_existing_account_userid" : "does-not-exist" } ] } ``` -------------------------------- ### Get Help for feditest run Source: https://feditest.org/reference/commands/run Displays detailed help information for the 'feditest run' command, outlining all available options and their usage. ```bash feditest run --help ``` -------------------------------- ### Clone FediTest Repository Source: https://feditest.org/blog/2023-08-11-swicg-presentation Clone the FediTest repository to your local machine. This is the initial setup step before running any tests. ```bash > git clone https://github.com/fediverse-devnet/feditest.git > cd feditest ``` -------------------------------- ### Install FediTest using PIP Source: https://feditest.org/quickstart/fediverse-developer/integrating-into-ci Install the FediTest package using pip. Ensure you are using a compatible Python version as specified by FediTest requirements. ```bash pip install feditest ``` -------------------------------- ### WebFinger JRD Response Example Source: https://feditest.org/assets/2024-06-05/index-annost.html An example of a JSON Resource Descriptor (JRD) response from a WebFinger server. It includes subject, aliases, properties, and a filtered 'links' array based on requested 'rel' parameters. ```json { "subject" : "acct:bob@example.com", "aliases" : [ "https://www.example.com/~bob/" ], "properties" : { "http://example.com/ns/role" : "employee" }, "links" : [ { "rel" : "http://webfinger.example/rel/profile-page", "href" : "https://www.example.com/~bob/" }, { "rel" : "http://webfinger.example/rel/businesscard", "href" : "https://www.example.com/~bob/bob.vcf" } ] } ``` -------------------------------- ### Check FediTest Version Source: https://feditest.org/release-notes/0.4 Verify your currently installed FediTest version after upgrading. ```bash % feditest version ``` -------------------------------- ### WebFinger Properties Example Source: https://feditest.org/assets/2024-06-05/index-annost.html Illustrates the 'properties' field within a JRD (JSON Resource Descriptor) for WebFinger. These properties must be defined in a WebFinger application specification. ```json "properties" : { "http://blgx.example.net/ns/version" : "1.3", "http://blgx.example.net/ns/ext" : null } ``` -------------------------------- ### JRD Link Relation Object Example Source: https://feditest.org/assets/2024-06-05/index-annost.html An example illustrating the 'properties' member within a JRD, used to convey additional information about the subject. ```json "properties" : { "http://webfinger.example/ns/name" : "Bob Smith" } ``` -------------------------------- ### Example 'properties' object in WebFinger Source: https://feditest.org/assets/2024-06-05/index-annost.html Illustrates the use of the 'properties' object to convey additional information about a link relation, using URIs as property identifiers. ```json "properties" : { "http://webfinger.example/mail/port" : "993" } ``` -------------------------------- ### Sandbox Protocol Server Logging Interfaces Source: https://feditest.org/quickstart/sandbox Extends the Sandbox server interface with methods to start logging client invocations and retrieve the log. ```python class SandboxMultServer(Node): def start_logging(self): ... def get_and_clear_log(self) -> List[SandboxLogEvent]: ... ``` -------------------------------- ### Example 'titles' object in WebFinger Source: https://feditest.org/assets/2024-06-05/index-annost.html Demonstrates the structure of the 'titles' object within a link relation object, showing language-tagged human-readable descriptions. ```json "titles" : { "en-us" : "The Magical World of Steve", "fr" : "Le Monde Magique de Steve" } ``` -------------------------------- ### Get Node Driver Information Source: https://feditest.org/reference/howtos/avoid-terminal-input Use this command to discover the configurable parameters for a specific FediTest Node Driver, which can then be added to your node configuration file. ```bash % feditest info --nodedriver FediverseSaasNodeDriver ``` -------------------------------- ### Handle Any URI Scheme for Resource Identifiers Source: https://feditest.org/contrib/results/2024-06-16/index.openlink-virtuoso.html Verifies that the WebFinger server accepts resource identifiers using any URI scheme. This example shows a test failure where a 400 was returned instead of the expected 404 for a mailto scheme. ```python AssertionFailure: Not HTTP status 404. Accessed URI: "https://fediverse.demo.openlinksw.com/.well-known/webfinger?resource=mailto%3Aabc%40def.com". Expected: <404> but: was <400> ../feditest-tests-fediverse//tests/webfinger/server/4_5__1_any_uri_scheme_for_resource_identifiers.py:35 ``` -------------------------------- ### Run FediTest with a Test Plan Source: https://feditest.org/blog/2024-09-13-feditest-session-at-fediforum Execute FediTest to run a predefined test plan. This command automates the setup of Mastodon instances, local hostnames, and TLS certificates, then performs API interactions to test following and posting functionality. ```bash feditest run --testplan ``` -------------------------------- ### Example Test Report Output Source: https://feditest.org/blog/2023-08-11-swicg-presentation Illustrative output format for test reports, showing potential errors and warnings encountered during test runs. ```text Report: … ERROR: app X: does not publish outbox in Actor file WARNING: Threads->Lemmy: post in cyrillic alphabet arrived with mangled characters … ``` -------------------------------- ### Run Two-Node Mastodon Test Source: https://feditest.org/quickstart/evaluate Executes a two-node Fediverse test scenario with two Mastodon instances. This command installs Mastodon instances within the container and generates an HTML report. ```bash $ feditest -v run \ --filter system2 \ --node sender_node=nodes/mastodon.ubos.node.json \ --node receiver_node=nodes/mastodon.ubos.node.json \ --name 'Mastodon vs Mastodon' \ --html results/mastodon-mastodon.html ``` -------------------------------- ### WebFinger Response with Web Page Metadata Source: https://feditest.org/assets/2024-06-05/index-annost.html Example JSON response from a WebFinger server containing metadata for a web page, including aliases, properties, and link relations like 'copyright' and 'author'. ```json { "subject" : "http://blog.example.com/article/id/314", "aliases" : [ "http://blog.example.com/cool_new_thing", "http://blog.example.com/steve/article/7" ], "properties" : { "http://blgx.example.net/ns/version" : "1.3", "http://blgx.example.net/ns/ext" : null }, "links" : [ { "rel" : "copyright", "href" : "http://www.example.com/copyright" }, { "rel" : "author", "href" : "http://blog.example.com/author/steve", "titles" : { "en-us" : "The Magical World of Steve", "fr" : "Le Monde Magique de Steve" }, "properties" : { "http://example.com/role" : "editor" } } ] } ``` -------------------------------- ### WebFinger Assertion Failure Example Source: https://feditest.org/contrib/results/2024-06-16/index.Wildebeest.html An example of an AssertionFailure during a WebFinger test, indicating an unexpected HTTP status code. ```python AssertionFailure: Not HTTP status 404. Accessed URI: "https://cloudflare.social/.well-known/webfinger?resource=mailto%3Aabc%40def.com". Expected: <404> but: was <400> ../feditest-tests-fediverse//tests/webfinger/server/4_5__1_any_uri_scheme_for_resource_identifiers.py:35 ``` -------------------------------- ### Create Sandbox Protocol Test Files Source: https://feditest.org/quickstart/sandbox Run the 'make create' command to generate the necessary JSON files for FediTest to use with the Sandbox protocol. ```bash $ make -f Makefile.create ``` -------------------------------- ### Run FediTest Source: https://feditest.org/blog/2024-04-09-earliest-access Navigate to the test suite directory and execute the FediTest command. ```bash % cd ../feditest-tests-fediverse % ../feditest/venv/bin/feditest ``` -------------------------------- ### WebFinger Server Test Failure Example Source: https://feditest.org/contrib/results/2024-06-16/index.catnip.html This snippet shows an example of an AssertionFailure during a WebFinger server test. It indicates that the server did not return the expected HTTP status code (404) for a given resource identifier. ```python AssertionFailure: Not HTTP status 404. Accessed URI: "https://foxgirl.land/.well-known/webfinger?resource=mailto%3Aabc%40def.com". Expected: <404> but: was <422> ../feditest-tests-fediverse//tests/webfinger/server/4_5__1_any_uri_scheme_for_resource_identifiers.py:35 ``` -------------------------------- ### Run Sandbox Protocol Tests Source: https://feditest.org/quickstart/sandbox Execute the Sandbox protocol tests using the 'make run' command. This will generate HTML reports in the examples/testresults/ directory. ```bash $ make -f Makefile.run ``` -------------------------------- ### WebFinger Server Test Failure Example Source: https://feditest.org/contrib/results/2024-06-16/index.Lemmy.html This snippet shows an example of an AssertionFailure during a WebFinger server test. It indicates that the server did not return the expected HTTP status code (404) for a query with a non-standard resource URI scheme. ```python Not HTTP status 404. "" AssertionFailure: Not HTTP status 404. Accessed URI: "https://lemmy.ml/.well-known/webfinger?resource=mailto%3Aabc%40def.com". Expected: <404> but: was <400> ../feditest-tests-fediverse//tests/webfinger/server/4_5__1_any_uri_scheme_for_resource_identifiers.py:35 ``` -------------------------------- ### Run Default Test Plan Source: https://feditest.org/blog/2024-04-09-earliest-access Execute the default test plan with verbose output enabled. ```bash % ../feditest/venv/bin/feditest -v run ``` -------------------------------- ### Upgrade FediTest Source: https://feditest.org/release-notes/0.4 Use this command to upgrade your FediTest installation via pip. ```bash % pip install --upgrade feditest ``` -------------------------------- ### Backup Application State with UBOS Gears Source: https://feditest.org/faq/feditest/role-of-ubos Use `ubos-admin backup` to create a backup file of the current application state, which can later be used with `ubos-admin restore`. ```bash ubos-admin backup ``` -------------------------------- ### Run All Tests in All Combinations Source: https://feditest.org/blog/2023-08-11-swicg-presentation Execute all known tests against all supported applications in all possible combinations. This is a comprehensive test run, though potentially infeasible due to the number of combinations. ```bash > feditest run –all ``` -------------------------------- ### Get Test Information Source: https://feditest.org/blog/2024-04-09-earliest-access Retrieve detailed information about a specific FediTest, identified by its name. ```bash % ../feditest/venv/bin/feditest info --test sandbox.test_1 ``` -------------------------------- ### Run Custom Test Plan Source: https://feditest.org/blog/2024-04-09-earliest-access Execute a specific, non-default test plan with verbose output. ```bash % ../feditest/venv/bin/feditest -v run --testplan example-testplans/feditest-sandbox.json ``` -------------------------------- ### Clone FediTest Repositories Source: https://feditest.org/blog/2024-04-09-earliest-access Clone the FediTest framework and the test suite repositories into your working directory. ```bash % git clone https://github.com/fediverse-devnet/feditest.git % git clone https://github.com/fediverse-devnet/feditest-tests-fediverse.git ``` -------------------------------- ### Handle Non-Existent Resources with 404 (Soft Failure) Source: https://feditest.org/assets/2024-06-05/webfinger-server-all-wellknown-saas-imp.sequential.html This test case verifies that the server returns a 404 status for non-existent resources, even when using different URI schemes like 'mailto'. It demonstrates a soft assertion failure. ```python SoftAssertionFailure: Not HTTP status 404. Accessed URI: "https://authorship.studio/.well-known/webfinger?resource=mailto%3Aabc%40def.com". Expected: <404> but: was <400> tests/webfinger/server/4_5__1_any_uri_scheme_for_resource_identifiers.py:25 ``` -------------------------------- ### WebFinger Response for OIDC Discovery Source: https://feditest.org/assets/2024-06-05/index-annost.html Example JSON response from a WebFinger server indicating the OpenID Connect issuer URL for a given resource. ```json { "subject" : "acct:carol@example.com", "links" : [ { "rel" : "http://openid.net/specs/connect/1.0/issuer", "href" : "https://openid.example.com" } ] } ``` -------------------------------- ### Restore Application State with UBOS Gears Source: https://feditest.org/faq/feditest/role-of-ubos Use `ubos-admin restore` with a UBOS backup file to revert an application to a previously saved state, including database content and uploaded media. ```bash ubos-admin restore ``` -------------------------------- ### WebFinger Client Query Issuance Source: https://feditest.org/assets/2024-06-05/index-annost.html Clients must use the GET method and direct queries to the '/.well-known/webfinger' URI with a single 'resource' parameter. ```text The client issues the query to the right URI. Tested there already. Resource parameter (client) ``` -------------------------------- ### WebFinger Query with Multiple Rel Parameters Source: https://feditest.org/contrib/results/2024-06-16/index.Bridgy-Fed.html Demonstrates a WebFinger query with multiple 'rel' parameters. This snippet highlights how Bridgy-Fed handles parameter ordering and specific rel values. ```python AssertionFailure: WebFinger errors (3) Accessed URI: "https://fed.brid.gy/.well-known/webfinger?resource=acct%3Afed.brid.gy%40fed.brid.gy&rel=http%3A//webfinger.net/rel/profile-page&rel=something-else&rel=self". 0: Link rel value not absolute URI nor registered relation type: "canonical_uri" 1: Link rel value not absolute URI nor registered relation type: "inbox" 2: Link rel value not absolute URI nor registered relation type: "sharedInbox" Expected: None but: was ../feditest-tests-fediverse//tests/webfinger/server/4_1__2_parameter_ordering_not_significant.py:30 ``` -------------------------------- ### Run All Interoperability Tests Source: https://feditest.org/blog/2023-08-11-swicg-presentation Execute all interoperability tests involving a specified application against all other supported applications. This checks how an app interacts with the wider Fediverse. ```bash > feditest run —interop —app mastodon –all ``` -------------------------------- ### Create Constellation from Node JSON Files Source: https://feditest.org/reference/commands/create-constellation Use this command to generate a Constellation JSON file. Pass the Node JSON files as arguments, annotating each with the role it will play in the Constellation. ```bash feditest create-constellation --help ``` -------------------------------- ### Normal WebFinger Query for Existing Account Source: https://feditest.org/contrib/results/2024-06-16/index.Bridgy-Fed.html Shows a standard WebFinger query for an existing account. This snippet illustrates the expected JRD response structure and potential issues with link rel values. ```python AssertionFailure: WebFinger errors (3) Accessed URI: "https://fed.brid.gy/.well-known/webfinger?resource=acct%3Afed.brid.gy%40fed.brid.gy". 0: Link rel value not absolute URI nor registered relation type: "canonical_uri" 1: Link rel value not absolute URI nor registered relation type: "inbox" 2: Link rel value not absolute URI nor registered relation type: "sharedInbox" Expected: None but: was ../feditest-tests-fediverse//tests/webfinger/server/4_2__2_perform_query.py:19 ``` -------------------------------- ### Clone Sandbox Protocol Tests Source: https://feditest.org/quickstart/sandbox Clone the Git repository containing the tests for the Sandbox protocol. This includes checking out the correct version based on the installed FediTest version. ```bash $ git clone --recurse-submodules \ https://github.com/fediverse-devnet/feditest-tests-sandbox.git $ cd feditest-tests-sandbox $ git checkout v$(feditest version) ``` -------------------------------- ### Initial FediTest Node Configuration Source: https://feditest.org/reference/howtos/avoid-terminal-input This is the basic structure of a FediTest node configuration file before any custom parameters are added. ```json { "nodedriver" : "FediverseSaasNodeDriver" } ``` -------------------------------- ### Handle Non-Existent Resources with 404 Source: https://feditest.org/assets/2024-06-05/webfinger-server-all-wellknown-saas-imp.sequential.html The server should respond with a 404 status code when a requested resource does not exist. This snippet shows a test case that verifies this behavior. ```python HardAssertionFailure: Not HTTP status 404. Accessed URI: "https://authorship.studio/.well-known/webfinger?resource=acct%3Adoes-not-exist%40authorship.studio". Expected: <404> but: was <400> tests/webfinger/server/4_2__5_status_404_for_nonexisting_resources.py:20 ``` -------------------------------- ### WebFinger JRD Content Type Test Source: https://feditest.org/contrib/results/2024-12-29T19.12.46/webfinger-server-all.testresult.31.html Asserts that a query over HTTPS returns a JRD with the correct content type. This test checks for 'application/jrd+json' or a string starting with it, and fails if 'application/json;charset=utf-8' is returned. ```python AssertionFailure (Must, Degraded): Wrong content type. ``` AssertionFailure: AssertionFailure (Must, Degraded): Wrong content type. Accessed URI: "https://gitea.moe/.well-known/webfinger?resource=acct%3Aav18%40gitea.moe". Expected: ('application/jrd+json' or a string starting with 'application/jrd+json;') but: was 'application/json;charset=utf-8' ./tests/webfinger/server/4_2__9_content_type.py:43 ``` ``` -------------------------------- ### Respond with 404 for Non-existent Resources Source: https://feditest.org/contrib/results/2024-06-16/index.Fedipage.html Verifies that the server returns a 404 Not Found status code when a resource parameter identifies a non-existent resource. ```python AssertionFailure: HTTP status 200. Accessed URI: "https://jeffreyfreeman.me/.well-known/webfinger?resource=acct%3Adoes-not-exist%40jeffreyfreeman.me". Expected: (a value greater than or equal to <300> or a value less than <200>) but: was <200> ../feditest-tests-fediverse//tests/webfinger/server/4_2__5_status_404_for_nonexisting_resources.py:21 ``` -------------------------------- ### WebFinger Request with Multiple Rel Parameters Source: https://feditest.org/assets/2024-06-05/index-annost.html Demonstrates a GET request to a WebFinger resource specifying multiple link relation types using the 'rel' parameter. The server is expected to filter links based on these parameters. ```http GET /.well-known/webfinger?\ resource=acct%3Abob%40example.com&\ rel=http%3A%2F%2Fwebfinger.example%2Frel%2Fprofile-page&\ rel=http%3A%2F%2Fwebfinger.example%2Frel%2Fbusinesscard HTTP/1.1 Host: example.com ``` -------------------------------- ### Handle Non-existent Resources with 404 Source: https://feditest.org/contrib/results/2024-06-16/index.capubara.html Verifies that the server returns a 404 status code for non-existent resources. This test failed, indicating the server returned a 500 status instead. ```python AssertionFailure: Not HTTP status 404. Accessed URI: "https://testserver.capubara.com/.well-known/webfinger?resource=acct%3Adoes-not-exist%40testserver.capubara.com". Expected: <404> but: was <500> ../feditest-tests-fediverse//tests/webfinger/server/4_2__5_status_404_for_nonexisting_resources.py:30 ``` -------------------------------- ### Run FediTest in Interactive Mode Source: https://feditest.org/reference/howtos/drilling-down-on-a-failing-test Use the --interactive flag to enable interactive mode, allowing you to pause and choose actions like re-running the previous test. This is useful for debugging time-consuming test setups. ```bash $ fedtest run --interactive ``` -------------------------------- ### List FediTest Test Sets Source: https://feditest.org/blog/2024-04-09-earliest-access List the available test sets for managing and organizing FediTests. ```bash % ../feditest/venv/bin/feditest list-testsets ``` -------------------------------- ### WebFinger Server Accepts Unknown Link Rels Source: https://feditest.org/assets/2024-06-05/webfinger-server-all-wellknown-saas-imp.sequential.html Tests that a WebFinger server accepts all link relation types in the query, even if it does not understand them. This snippet shows an example of a failed assertion where an unknown link rel was not handled as expected. ```python HardAssertionFailure: WebFinger errors (3) Accessed URI: "https://authorship.studio/.well-known/webfinger?resource=acct%3Ascott%40authorship.studio". 0: Link type not a valid media type: "" 1: Link rel value not absolute URI nor registered relation type: "magic-public-key" 2: Link href not a URI: "data:application/magic-public-key,RSA.vBaccO-wjQ9hQ6cb23a1CV0cv8QVH7Cu_KR55ogX5uJ-IW4uMcxmLQkyw_5oFbZOgjvDxm7zDqkDp45R2aICyRmcpjSy2-sREM7OBzin9GY3N4EYrXNdl6eamrSk8v3gArIe_UbwoEzXzM4lcvutZGqgjoo_42j1eaAYGG_Wyzs7K3GFVJBOwYS6us_k9noF8sUE-vJI0c9UEbODNfyUsPC-R_n--lECAkV04a_FDqCztkqExtz2xpXnNs-yuHij4e1g3QAvcaUmIKhD2DzGU70pt1y4q9vZ-U_D092wGQ6fQ48r6_GG9c4yWwOxeKZfT0E8Bg5YP3NW6aGxrZA4OKkW3UFhTWFlBK_7DNcsuzZBA8Svt5kjJYO89xYfTAQ3ywgkKQG13_KdF2iRzlCSBv5qq2obBsdqOfoibd9la4tC0RY6R934DLlhHvGX57gKtbm1Fc1fOXwCYd5YMXPa1ewG2dD02fZ4h1zeZL2uqlzkrSEE6tiMcaux7I63q1y0MW2NFIp8i65BeSsHDcKR1khiDmjxN-OZLgJ7PpJM6C7xKj1V_YxP8lD5uCFFUlD9v4F1j1wa0aQ-I9nOfVwJRcfCyQvXDWyen9vne8XOXV1Kb8qm7FCyrUs4WHt5AZaXC5em-RMlFM7eY-YAnxcsRAMnWdbqj5wXroPxEypQn60.AQAB" Expected: No exception other than: WrongContentTypeError,InvalidMediaTypeError,InvalidRelError but: was tests/webfinger/server/4__1_accepts_all_link_rels_in_query.py:90 ``` -------------------------------- ### Test Content Type for HTTPS Request Source: https://feditest.org/contrib/results/2024-10-24T22.02.04/webfinger-server-all.testresult.45.html This test checks if a query over HTTPS correctly returns a JRD (JSON Resource Descriptor) with the expected content type. The example shows an assertion failure where the server returned 'application/json; charset=utf-8' instead of 'application/jrd+json'. ```python AssertionFailure (Must, Degraded): Wrong content type. AssertionFailure: AssertionFailure (Must, Degraded): Wrong content type. Accessed URI: "https://juick.com/.well-known/webfinger?resource=acct%3Anetneladno%40juick.com". Expected: ('application/jrd+json' or a string starting with 'application/jrd+json;') but: was 'application/json; charset=utf-8' ../feditest-tests-fediverse/tests/webfinger/server/4_2__9_content_type.py:44 ``` -------------------------------- ### WebFinger Server: 404 for Non-existent Resources Source: https://feditest.org/contrib/results/2024-06-16/index.ActivityRelay.html Verifies that the server returns a 404 Not Found status code when a request is made for a resource that does not exist. ```python def status_404_for_nonexisting_resources(self): """The server responds with 404 when the resource parameter identifies a non-existent resource.""" self.assert_status_code(404) ``` -------------------------------- ### Test HTTP Status for Non-existent Resource Source: https://feditest.org/contrib/results/2024-10-24T22.02.04/webfinger-server-all.testresult.45.html This test verifies that the server responds with an HTTP 400 status code when a resource identifier uses an unsupported URI scheme (e.g., 'mailto:' instead of 'acct:'). The example shows an assertion failure where a 400 was returned instead of the expected 404. ```python AssertionFailure (Must, Unaffected): Not HTTP status 404. AssertionFailure: AssertionFailure (Must, Unaffected): Not HTTP status 404. Accessed URI: "https://juick.com/.well-known/webfinger?resource=mailto%3Aabc%40def.com". Expected: <404> but: was <400> ../feditest-tests-fediverse/tests/webfinger/server/4_5__1_any_uri_scheme_for_resource_identifiers.py:38 ``` -------------------------------- ### Webfinger Server: 404 for Non-existent Resources Source: https://feditest.org/contrib/results/2024-06-16/index.Pixelfed.html Verifies that the server returns a 404 status code for non-existent resources. This test checks for an expected 404 but received a 400. ```python AssertionFailure: Not HTTP status 404. Accessed URI: "https://pixelfed.social/.well-known/webfinger?resource=acct%3Adoes-not-exist%40pixelfed.social". Expected: <404> but: was <400> ../feditest-tests-fediverse//tests/webfinger/server/4_2__5_status_404_for_nonexisting_resources.py:30 ``` -------------------------------- ### Handle Malformed Resource Parameters (Missing Scheme JRD) Source: https://feditest.org/contrib/results/2024-12-29T19.12.46/webfinger-server-all.testresult.19.html Tests the JRD content when resource parameters are malformed due to a missing 'acct:' scheme. ```python def requires_valid_resource_uri_jrd(self): """Do not accept malformed resource parameters. Test JRD content for missing acct: scheme.""" self.assert_request_fails( "/.well-known/webfinger?resource=wspd7pio@bird.makeup", expected_status=400, expected_content_type='application/jrd+json', ) ``` -------------------------------- ### Handle Non-existent Resources with Any URI Scheme Source: https://feditest.org/contrib/results/2024-12-29T19.12.46/webfinger-server-all.testresult.21.html Tests the server's ability to handle resource identifiers using various URI schemes, expecting a 404 for non-existent mailto resources. This snippet indicates a failure where a 400 Bad Request was returned. ```python AssertionFailure: AssertionFailure (Must, Unaffected): Not HTTP status 404. Accessed URI: "https://pate.social/.well-known/webfinger?resource=mailto%3Aabc%40def.com". Expected: <404> but: was <400> ./tests/webfinger/server/4_5__1_any_uri_scheme_for_resource_identifiers.py:37 ``` -------------------------------- ### WebFinger Server Normal Query Source: https://feditest.org/assets/2024-06-05/webfinger-server-all-wellknown-saas-imp.sequential.html Performs a standard, simple WebFinger query for an existing account. ```python def normal_query(self): """Perform a normal, simple query on an existing account.""" self.assert_request_succeeds( self.make_request(resource=self.make_resource(username="test", domain="example.com")) ) ``` -------------------------------- ### Run Fediverse Test Plan Source: https://feditest.org/quickstart/fediverse-developer/fediverse-mastodon-cloud Execute the configured TestPlan to run tests between your application and the Mastodon instance. The results are saved in an HTML file. ```bash $ feditest run --testplan myapp-follow-mastodon-ubos-ec2.json --html myapp-follow-mastodon-ubos-ec2-results.html ``` -------------------------------- ### Handle 404 for Non-existent Resources Source: https://feditest.org/contrib/results/2024-06-16/index.notestock.html Verifies that the server returns a 404 status code when a requested resource does not exist. This test checks the server's behavior for invalid resource identifiers. ```python AssertionFailure: HTTP status 200. Accessed URI: "https://notestock.osa-p.net/.well-known/webfinger?resource=acct%3Adoes-not-exist%40notestock.osa-p.net". Expected: (a value greater than or equal to <300> or a value less than <200>) but: was <200> ../feditest-tests-fediverse//tests/webfinger/server/4_2__5_status_404_for_nonexisting_resources.py:21 ``` -------------------------------- ### WebFinger Server Test: Normal Query Source: https://feditest.org/contrib/results/2024-06-16/index.foundkey.html Executes a standard query against an existing account to ensure proper functionality. This test passed. ```python Started 2024-06-16T22:47:53.757563+00:00, ended 2024-06-16T22:47:54.358082+00:00 Passed ```