Sha256: ebf5b70d37ca1af620cab8492a90036c3bb37db917d1608fb76723bfba03b834
Contents?: true
Size: 615 Bytes
Versions: 31
Compression:
Stored size: 615 Bytes
Contents
u = up.util beforeEach -> jasmine.addMatchers toHaveRequestMethod: (util, customEqualityTesters) -> compare: (request, expectedMethod) -> realMethodMatches = (request.method == expectedMethod) formData = request.data() if u.isFormData(formData) wrappedMethod = formData.get('_method') wrappedMethodMatches = (wrappedMethod == expectedMethod) else wrappedMethod = formData['_method'] wrappedMethodMatches = util.equals(wrappedMethod, [expectedMethod], customEqualityTesters) pass: realMethodMatches || wrappedMethodMatches
Version data entries
31 entries across 31 versions & 1 rubygems