Search Options

Results per page
Sort
Preferred Languages
Advance

Results 521 - 530 of 1,039 for AssertJ (0.05 sec)

  1. tests/test_http_connection_injection.py

    
    client = TestClient(app)
    
    
    def test_value_extracting_by_http():
        response = client.get("/http")
        assert response.status_code == 200
        assert response.json() == 42
    
    
    def test_value_extracting_by_ws():
        with client.websocket_connect("/ws") as websocket:
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Aug 09 13:56:41 UTC 2020
    - 972 bytes
    - Viewed (0)
  2. tests/test_tutorial/test_response_model/test_tutorial003_01.py

            },
        )
        assert response.status_code == 200, response.text
        assert response.json() == {
            "username": "foo",
            "email": "******@****.***",
            "full_name": "Grave Dohl",
        }
    
    
    def test_openapi_schema():
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "openapi": "3.1.0",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Aug 04 20:47:07 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  3. okhttp-coroutines/src/test/kotlin/okhttp3/coroutines/ExecuteAsyncTest.kt

     * See the License for the specific language governing permissions and
     * limitations under the License.
     *
     */
    package okhttp3.coroutines
    
    import assertk.assertThat
    import assertk.assertions.isEqualTo
    import assertk.assertions.isTrue
    import java.io.IOException
    import java.util.concurrent.TimeUnit
    import kotlin.test.assertFailsWith
    import kotlin.time.Duration.Companion.seconds
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Apr 18 01:24:38 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/net/UrlEscaperTesting.java

    import static com.google.common.escape.testing.EscaperAsserts.assertUnescaped;
    import static com.google.common.escape.testing.EscaperAsserts.assertUnicodeEscaping;
    import static junit.framework.Assert.assertEquals;
    import static junit.framework.Assert.fail;
    
    import com.google.common.annotations.GwtCompatible;
    import com.google.common.escape.UnicodeEscaper;
    
    /**
     * Testing utilities for {@link UrlEscapers} and {@link LegacyUrlEscapersTest}.
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 17:53:22 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/CallKotlinTest.kt

     * See the License for the specific language governing permissions and
     * limitations under the License.
     */
    package okhttp3
    
    import assertk.assertThat
    import assertk.assertions.isEqualTo
    import assertk.assertions.isInstanceOf
    import assertk.assertions.isNotSameAs
    import java.io.IOException
    import java.net.Proxy
    import java.security.cert.X509Certificate
    import java.time.Duration
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 8.4K bytes
    - Viewed (0)
  6. tests/test_tutorial/test_response_model/test_tutorial003_py310.py

                "full_name": "Grave Dohl",
            },
        )
        assert response.status_code == 200, response.text
        assert response.json() == {
            "username": "foo",
            "email": "******@****.***",
            "full_name": "Grave Dohl",
        }
    
    
    @needs_py310
    def test_openapi_schema(client: TestClient):
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Aug 04 20:47:07 UTC 2023
    - 5.8K bytes
    - Viewed (0)
  7. tests/test_tutorial/test_dependencies/test_tutorial004_an_py310.py

        response = client.get(path)
        assert response.status_code == expected_status
        assert response.json() == expected_response
    
    
    @needs_py310
    def test_openapi_schema(client: TestClient):
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "openapi": "3.1.0",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  8. tests/test_tutorial/test_extra_data_types/test_tutorial001.py

            }
        )
        response = client.put(f"/items/{item_id}", json=data)
        assert response.status_code == 200, response.text
        assert response.json() == expected_response
    
    
    def test_openapi_schema():
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "openapi": "3.1.0",
            "info": {"title": "FastAPI", "version": "0.1.0"},
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Apr 19 00:11:40 UTC 2024
    - 6.8K bytes
    - Viewed (0)
  9. tests/test_tutorial/test_schema_extra_example/test_tutorial004_an.py

                "description": "A very nice Item",
                "price": 35.4,
                "tax": 3.2,
            },
        )
        assert response.status_code == 200
    
    
    def test_openapi_schema():
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "openapi": "3.1.0",
            "info": {"title": "FastAPI", "version": "0.1.0"},
            "paths": {
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 6.9K bytes
    - Viewed (0)
  10. tests/test_tutorial/test_schema_extra_example/test_tutorial001_py310.py

                "price": 35.4,
                "tax": 3.2,
            },
        )
        assert response.status_code == 200
    
    
    @needs_py310
    @needs_pydanticv2
    def test_openapi_schema(client: TestClient):
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
        # insert_assert(response.json())
        assert response.json() == {
            "openapi": "3.1.0",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 4.7K bytes
    - Viewed (0)
Back to top