1
0
Fork 0
gobject-generator/regression/tier6/SoupSmoke.swift

29 lines
1.2 KiB
Swift

// SoupSmoke.swift
// Tier-6-only runtime smoke test for Soup (Phase E5). Proves against the
// REAL libsoup-3.0, linked at runtime that the generated bindings reach
// real Soup C symbols.
//
// `getMajorVersion()`/`getMinorVersion()` reach `soup_get_major_version`/
// `soup_get_minor_version`, plain free functions that need no session,
// message, or network connection display/network-free by construction.
// Uses only plain-public API no `@_spi` import.
//
// Not generated. `scripts/smoke-test.sh <tier>` copies tier 1 and the selected
// tier's fixtures for tiers 2 through 5. Tier 6/all copies every tier's fixtures
// into one full-stack SmokeTests target. Only installed for tier >= 6.
import Testing
import GLib
import Soup
@Suite("Tier 6 Soup smoke tests")
struct SoupSmokeTests {
@Test("getMajorVersion()/getMinorVersion() reach the real soup_get_major_version/soup_get_minor_version and report libsoup 3")
func versionFunctionsReachRealSoup() throws {
#expect(getMajorVersion() == 3)
// libsoup 3's minor version is a real, non-placeholder value
// reported by the linked library, not a stubbed default.
#expect(getMinorVersion() >= 0)
}
}