• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

hazendaz / httpunit / 755

14 Feb 2026 07:14PM UTC coverage: 80.526%. Remained the same
755

push

github

hazendaz
[ci] Fix badge

3213 of 4105 branches covered (78.27%)

Branch coverage included in aggregate %.

8245 of 10124 relevant lines covered (81.44%)

0.81 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

73.68
/src/main/java/com/meterware/servletunit/ServletUnitHttpResponse.java
1
/*
2
 * SPDX-License-Identifier: MIT
3
 * See LICENSE file for details.
4
 *
5
 * Copyright 2000-2026 Russell Gold
6
 * Copyright 2021-2000 hazendaz
7
 */
8
package com.meterware.servletunit;
9

10
import com.meterware.httpunit.HttpUnitUtils;
11

12
import jakarta.servlet.ServletOutputStream;
13
import jakarta.servlet.WriteListener;
14
import jakarta.servlet.http.Cookie;
15
import jakarta.servlet.http.HttpServletResponse;
16

17
import java.io.ByteArrayOutputStream;
18
import java.io.IOException;
19
import java.io.OutputStreamWriter;
20
import java.io.PrintWriter;
21
import java.nio.charset.Charset;
22
import java.nio.charset.StandardCharsets;
23
import java.text.SimpleDateFormat;
24
import java.util.ArrayList;
25
import java.util.Collection;
26
import java.util.Collections;
27
import java.util.Date;
28
import java.util.Enumeration;
29
import java.util.Hashtable;
30
import java.util.Iterator;
31
import java.util.List;
32
import java.util.Locale;
33
import java.util.Map;
34
import java.util.TimeZone;
35

36
/**
37
 * The Class ServletUnitHttpResponse.
38
 */
39
class ServletUnitHttpResponse implements HttpServletResponse {
1✔
40

41
    /** The Constant RFC1123_DATE_SPEC. */
42
    // rfc1123-date is "Sun, 06 Nov 1994 08:49:37 GMT"
43
    private static final String RFC1123_DATE_SPEC = "EEE, dd MMM yyyy HH:mm:ss z";
44

45
    /** The committed. */
46
    private boolean _committed;
47

48
    /** The locale. */
49
    private Locale _locale = Locale.getDefault();
1✔
50

51
    /** The Constant ENCODING_MAP. */
52
    private static final Hashtable ENCODING_MAP = new Hashtable<>();
1✔
53

54
    /**
55
     * Adds the specified cookie to the response. It can be called multiple times to set more than one cookie.
56
     */
57
    @Override
58
    public void addCookie(Cookie cookie) {
59
        _cookies.add(cookie);
1✔
60
    }
1✔
61

62
    /**
63
     * Checks whether the response message header has a field with the specified name.
64
     */
65
    @Override
66
    public boolean containsHeader(String name) {
67
        return _headers.containsKey(name.toUpperCase());
1✔
68
    }
69

70
    /**
71
     * Encodes the specified URL by including the session ID in it, or, if encoding is not needed, returns the URL
72
     * unchanged. The implementation of this method should include the logic to determine whether the session ID needs
73
     * to be encoded in the URL. For example, if the browser supports cookies, or session tracking is turned off, URL
74
     * encoding is unnecessary.
75
     **/
76
    @Override
77
    public String encodeURL(String url) {
78
        return url;
×
79
    }
80

81
    /**
82
     * Encodes the specified URL for use in the <code>sendRedirect</code> method or, if encoding is not needed, returns
83
     * the URL unchanged. The implementation of this method should include the logic to determine whether the session ID
84
     * needs to be encoded in the URL. Because the rules for making this determination differ from those used to decide
85
     * whether to encode a normal link, this method is seperate from the <code>encodeUrl</code> method.
86
     **/
87
    @Override
88
    public String encodeRedirectURL(String url) {
89
        return url;
×
90
    }
91

92
    /**
93
     * Sends a temporary redirect response to the client using the specified redirect location URL. The URL must be
94
     * absolute (for example, <code><em>https://hostname/path/file.html</em></code>). Relative URLs are not permitted
95
     * here.
96
     */
97
    @Override
98
    public void sendRedirect(String location) throws IOException {
99
        setStatus(HttpServletResponse.SC_MOVED_TEMPORARILY);
1✔
100
        setHeader("Location", location);
1✔
101
    }
1✔
102

103
    /**
104
     * Sends an error response to the client using the specified status code and descriptive message. If setStatus has
105
     * previously been called, it is reset to the error status code. The message is sent as the body of an HTML page,
106
     * which is returned to the user to describe the problem. The page is sent with a default HTML header; the message
107
     * is enclosed in simple body tags (&lt;body&gt;&lt;/body&gt;).
108
     **/
109
    @Override
110
    public void sendError(int sc) throws IOException {
111
        sendError(sc, "");
×
112
    }
×
113

114
    /**
115
     * Sends an error response to the client using the specified status code and descriptive message. If setStatus has
116
     * previously been called, it is reset to the error status code. The message is sent as the body of an HTML page,
117
     * which is returned to the user to describe the problem. The page is sent with a default HTML header; the message
118
     * is enclosed in simple body tags (&lt;body&gt;&lt;/body&gt;).
119
     **/
120
    @Override
121
    public void sendError(int sc, String msg) throws IOException {
122
        setStatus(sc);
×
123
        _statusMessage = msg;
×
124

125
        _writer = null;
×
126
        _servletStream = null;
×
127

128
        setContentType("text/html");
×
129
        getWriter().println("<html><head><title>" + msg + "</title></head><body>" + msg + "</body></html>");
×
130
    }
×
131

132
    /**
133
     * Sets the status code for this response. This method is used to set the return status code when there is no error
134
     * (for example, for the status codes SC_OK or SC_MOVED_TEMPORARILY). If there is an error, the
135
     * <code>sendError</code> method should be used instead.
136
     **/
137
    @Override
138
    public void setStatus(int sc) {
139
        _status = sc;
1✔
140
    }
1✔
141

142
    /**
143
     * Adds a field to the response header with the given name and value. If the field had already been set, the new
144
     * value overwrites the previous one. The <code>containsHeader</code> method can be used to test for the presence of
145
     * a header before setting its value.
146
     **/
147
    @Override
148
    public void setHeader(String name, String value) {
149
        ArrayList values = new ArrayList<>();
1✔
150
        values.add(value);
1✔
151
        synchronized (_headers) {
1✔
152
            _headers.put(name.toUpperCase(), values);
1✔
153
        }
1✔
154
    }
1✔
155

156
    /**
157
     * Adds a field to the response header with the given name and integer value. If the field had already been set, the
158
     * new value overwrites the previous one. The <code>containsHeader</code> method can be used to test for the
159
     * presence of a header before setting its value.
160
     **/
161
    @Override
162
    public void setIntHeader(String name, int value) {
163
        setHeader(name, asHeaderValue(value));
1✔
164
    }
1✔
165

166
    /**
167
     * Adds a field to the response header with the given name and integer value. If the field had already been set, the
168
     * new value overwrites the previous one. The <code>containsHeader</code> method can be used to test for the
169
     * presence of a header before setting its value.
170
     *
171
     * @param name
172
     *            the name
173
     * @param value
174
     *            the value
175
     */
176
    public void setLongHeader(String name, long value) {
177
        setHeader(name, asHeaderLongValue(value));
×
178
    }
×
179

180
    /**
181
     * As header value.
182
     *
183
     * @param value
184
     *            the value
185
     *
186
     * @return the string
187
     */
188
    private String asHeaderValue(int value) {
189
        return Integer.toString(value);
1✔
190
    }
191

192
    /**
193
     * As header long value.
194
     *
195
     * @param value
196
     *            the value
197
     *
198
     * @return the string
199
     */
200
    private String asHeaderLongValue(long value) {
201
        return Long.toString(value);
×
202
    }
203

204
    /**
205
     * Adds a field to the response header with the given name and date-valued field. The date is specified in terms of
206
     * milliseconds since the epoch. If the date field had already been set, the new value overwrites the previous one.
207
     * The <code>containsHeader</code> method can be used to test for the presence of a header before setting its value.
208
     **/
209
    @Override
210
    public void setDateHeader(String name, long date) {
211
        setHeader(name, asDateHeaderValue(date));
1✔
212
    }
1✔
213

214
    /**
215
     * As date header value.
216
     *
217
     * @param date
218
     *            the date
219
     *
220
     * @return the string
221
     */
222
    private String asDateHeaderValue(long date) {
223
        Date value = new Date(date);
1✔
224
        SimpleDateFormat formatter = new SimpleDateFormat(RFC1123_DATE_SPEC, Locale.US);
1✔
225
        formatter.setTimeZone(TimeZone.getTimeZone("Greenwich Mean Time"));
1✔
226
        return formatter.format(value);
1✔
227
    }
228

229
    /**
230
     * Returns the name of the character set encoding used for the MIME body sent by this response.
231
     **/
232
    @Override
233
    public String getCharacterEncoding() {
234
        return _encoding == null ? StandardCharsets.ISO_8859_1.name() : _encoding;
1✔
235
    }
236

237
    /**
238
     * Sets the content type of the response the server sends to the client. The content type may include the type of
239
     * character encoding used, for example, <code>text/html; charset=ISO-8859-4</code>.
240
     * <p>
241
     * You can only use this method once, and you should call it before you obtain a <code>PrintWriter</code> or
242
     * {@link ServletOutputStream} object to return a response.
243
     **/
244
    @Override
245
    public void setContentType(String type) {
246
        String[] typeAndEncoding = HttpUnitUtils.parseContentTypeHeader(type);
1✔
247

248
        _contentType = typeAndEncoding[0];
1✔
249
        if (typeAndEncoding[1] != null) {
1✔
250
            _encoding = typeAndEncoding[1];
1✔
251
        }
252
    }
1✔
253

254
    /**
255
     * Returns a {@link ServletOutputStream} suitable for writing binary data in the response. The servlet engine does
256
     * not encode the binary data.
257
     *
258
     * @exception IllegalStateException
259
     *                if you have already called the <code>getWriter</code> method
260
     **/
261
    @Override
262
    public ServletOutputStream getOutputStream() throws IOException {
263
        if (_writer != null) {
1✔
264
            throw new IllegalStateException("Tried to create output stream; writer already exists");
1✔
265
        }
266
        if (_servletStream == null) {
1✔
267
            _outputStream = new ByteArrayOutputStream();
1✔
268
            _servletStream = new ServletUnitOutputStream(_outputStream);
1✔
269
        }
270
        return _servletStream;
1✔
271
    }
272

273
    /**
274
     * Returns a <code>PrintWriter</code> object that you can use to send character text to the client. The character
275
     * encoding used is the one specified in the <code>charset=</code> property of the {@link #setContentType} method,
276
     * which you must call <i>before</i> you call this method.
277
     * <p>
278
     * If necessary, the MIME type of the response is modified to reflect the character encoding used.
279
     * <p>
280
     * You cannot use this method if you have already called {@link #getOutputStream} for this
281
     * <code>ServletResponse</code> object.
282
     *
283
     * @exception IllegalStateException
284
     *                if the <code>getOutputStream</code> method has already been called for this response object; in
285
     *                that case, you can't use this method
286
     **/
287
    @Override
288
    public PrintWriter getWriter() {
289
        if (_servletStream != null) {
1✔
290
            throw new IllegalStateException("Tried to create writer; output stream already exists");
1✔
291
        }
292
        if (_writer == null) {
1✔
293
            _outputStream = new ByteArrayOutputStream();
1✔
294
            _writer = new PrintWriter(new OutputStreamWriter(_outputStream, Charset.forName(getCharacterEncoding())));
1✔
295
        }
296
        return _writer;
1✔
297
    }
298

299
    /**
300
     * Sets the length of the content the server returns to the client. In HTTP servlets, this method sets the HTTP
301
     * Content-Length header.
302
     **/
303
    @Override
304
    public void setContentLength(int len) {
305
        setIntHeader("Content-Length", len);
1✔
306
    }
1✔
307

308
    // ------------------------------- the following methods are new in JSDK 2.2 ----------------------
309

310
    /**
311
     * Adds a response header with the given name and value. This method allows response headers to have multiple
312
     * values.
313
     **/
314
    @Override
315
    public void addHeader(String name, String value) {
316
        synchronized (_headers) {
1✔
317
            String key = name.toUpperCase();
1✔
318
            List values = (ArrayList) _headers.get(key);
1✔
319
            if (values == null) {
1✔
320
                values = new ArrayList<>();
1✔
321
                _headers.put(key, values);
1✔
322
            }
323
            values.add(value);
1✔
324
        }
1✔
325
    }
1✔
326

327
    /**
328
     * Adds a response header with the given name and value. This method allows response headers to have multiple
329
     * values.
330
     **/
331
    @Override
332
    public void addIntHeader(String name, int value) {
333
        addHeader(name, asHeaderValue(value));
1✔
334
    }
1✔
335

336
    /**
337
     * Adds a response header with the given name and value. This method allows response headers to have multiple
338
     * values.
339
     **/
340
    @Override
341
    public void addDateHeader(String name, long value) {
342
        addHeader(name, asDateHeaderValue(value));
1✔
343
    }
1✔
344

345
    /**
346
     * Sets the preferred buffer size for the body of the response. The servlet container will use a buffer at least as
347
     * large as the size requested. The actual buffer size used can be found using getBufferSize.
348
     **/
349
    @Override
350
    public void setBufferSize(int size) {
351
        if (getContents().length != 0) {
1✔
352
            throw new IllegalStateException("May not set buffer size after data is written");
1✔
353
        }
354
    }
1✔
355

356
    /**
357
     * Returns the actual buffer size used for the response. If no buffering is used, this method returns 0.
358
     **/
359
    @Override
360
    public int getBufferSize() {
361
        return 0;
×
362
    }
363

364
    /**
365
     * Returns a boolean indicating if the response has been committed. A committed response has already had its status
366
     * code and headers written.
367
     **/
368
    @Override
369
    public boolean isCommitted() {
370
        return _committed;
1✔
371
    }
372

373
    /**
374
     * Forces any content in the buffer to be written to the client. A call to this method automatically commits the
375
     * response, meaning the status code and headers will be written.
376
     **/
377
    @Override
378
    public void flushBuffer() throws IOException {
379
        _committed = true;
1✔
380
    }
1✔
381

382
    /**
383
     * Clears any data that exists in the buffer as well as the status code and headers. If the response has been
384
     * committed, this method throws an IllegalStateException.
385
     **/
386
    @Override
387
    public void reset() {
388
        resetBuffer();
1✔
389
        _headers.clear();
1✔
390
        _headersComplete = false;
1✔
391
        _status = SC_OK;
1✔
392
    }
1✔
393

394
    /**
395
     * Sets the locale of the response, setting the headers (including the Content-Type's charset) as appropriate. This
396
     * method should be called before a call to getWriter(). By default, the response locale is the default locale for
397
     * the server.
398
     **/
399
    @Override
400
    public void setLocale(Locale locale) {
401
        _locale = locale;
1✔
402
        if (_encoding == null) {
1!
403
            for (Iterator it = ENCODING_MAP.entrySet().iterator(); it.hasNext();) {
1!
404
                Map.Entry entry = (Map.Entry) it.next();
1✔
405
                String locales = (String) entry.getValue();
1✔
406
                if (locales.indexOf(locale.getLanguage()) >= 0 || locales.indexOf(locale.toString()) >= 0) {
1!
407
                    _encoding = (String) entry.getKey();
1✔
408
                    return;
1✔
409
                }
410
            }
1✔
411
        }
412
    }
×
413

414
    /**
415
     * Returns the locale assigned to the response.
416
     **/
417
    @Override
418
    public Locale getLocale() {
419
        return _locale;
1✔
420
    }
421

422
    // ----------------------------- methods added to ServletResponse in JSDK 2.3 --------------------------------------
423

424
    /**
425
     * Clears the content of the underlying buffer in the response without clearing headers or status code. If the
426
     * response has been committed, this method throws an IllegalStateException.
427
     */
428
    @Override
429
    public void resetBuffer() {
430
        if (_committed) {
1✔
431
            throw new IllegalStateException("May not resetBuffer after response is committed");
1✔
432
        }
433
        _outputStream = null;
1✔
434
        _servletStream = null;
1✔
435
        _writer = null;
1✔
436
    }
1✔
437

438
    // ---------------------------------------------- package methods --------------------------------------------------
439

440
    /**
441
     * Returns the contents of this response.
442
     *
443
     * @return the contents
444
     */
445
    byte[] getContents() {
446
        if (_outputStream == null) {
1✔
447
            return new byte[0];
1✔
448
        }
449
        if (_writer != null) {
1✔
450
            _writer.flush();
1✔
451
        }
452
        return _outputStream.toByteArray();
1✔
453
    }
454

455
    /**
456
     * Returns the status of this response.
457
     **/
458
    @Override
459
    public int getStatus() {
460
        return _status;
1✔
461
    }
462

463
    /**
464
     * Returns the message associated with this response's status.
465
     *
466
     * @return the message
467
     */
468
    String getMessage() {
469
        return _statusMessage;
×
470
    }
471

472
    /**
473
     * Gets the header field names.
474
     *
475
     * @return the header field names
476
     */
477
    public String[] getHeaderFieldNames() {
478
        if (!_headersComplete) {
×
479
            completeHeaders();
×
480
        }
481
        List<String> names = new ArrayList<>();
×
482
        for (Enumeration e = _headers.keys(); e.hasMoreElements();) {
×
483
            names.add((String) e.nextElement());
×
484
        }
485
        return names.toArray(new String[0]);
×
486
    }
487

488
    /**
489
     * Returns the headers defined for this response.
490
     *
491
     * @param name
492
     *            - the name of the field to get
493
     *
494
     * @return the header field direct
495
     */
496
    String getHeaderFieldDirect(String name) {
497
        ArrayList values;
498
        synchronized (_headers) {
1✔
499
            values = (ArrayList) _headers.get(name.toUpperCase());
1✔
500
        }
1✔
501

502
        return values == null ? null : (String) values.get(0);
1✔
503
    }
504

505
    /**
506
     * Returns the headers defined for this response.
507
     *
508
     * @param name
509
     *            the name
510
     *
511
     * @return the header field
512
     */
513
    String getHeaderField(String name) {
514
        if (!_headersComplete) {
1✔
515
            completeHeaders();
1✔
516
        }
517
        return getHeaderFieldDirect(name);
1✔
518
    }
519

520
    /**
521
     * Return an array of all the header values associated with the specified header name, or an zero-length array if
522
     * there are no such header values.
523
     *
524
     * @param name
525
     *            Header name to look up
526
     *
527
     * @return the header fields
528
     */
529
    public String[] getHeaderFields(String name) {
530
        if (!_headersComplete) {
1✔
531
            completeHeaders();
1✔
532
        }
533
        ArrayList values;
534
        synchronized (_headers) {
1✔
535
            values = (ArrayList) _headers.get(name.toUpperCase());
1✔
536
        }
1✔
537
        if (values == null) {
1✔
538
            return new String[0];
1✔
539
        }
540
        String[] results = new String[values.size()];
1✔
541
        return (String[]) values.toArray(results);
1✔
542

543
    }
544

545
    // --------------------------------------- methods added to ServletRequest in Servlet API 2.4
546
    // ----------------------------
547

548
    @Override
549
    public void setCharacterEncoding(String string) {
550
        _encoding = string;
×
551
    }
×
552

553
    /**
554
     * Returns the content type defined for this response.
555
     **/
556
    @Override
557
    public String getContentType() {
558
        return _contentType;
×
559
    }
560

561
    // ------------------------------------------- private members ------------------------------------
562

563
    /** The content type. */
564
    private String _contentType = "text/plain";
1✔
565

566
    /** The encoding. */
567
    private String _encoding;
568

569
    /** The writer. */
570
    private PrintWriter _writer;
571

572
    /** The servlet stream. */
573
    private ServletOutputStream _servletStream;
574

575
    /** The output stream. */
576
    private ByteArrayOutputStream _outputStream;
577

578
    /** The status. */
579
    private int _status = SC_OK;
1✔
580

581
    /** The status message. */
582
    private String _statusMessage = "OK";
1✔
583

584
    /** The headers. */
585
    private final Hashtable _headers = new Hashtable<>();
1✔
586

587
    /** The headers complete. */
588
    private boolean _headersComplete;
589

590
    /** The cookies. */
591
    private List<Cookie> _cookies = new ArrayList<>();
1✔
592

593
    /**
594
     * Complete headers.
595
     */
596
    private void completeHeaders() {
597
        if (_headersComplete) {
1!
598
            return;
×
599
        }
600
        addCookieHeader();
1✔
601
        // BR 3301056 ServletUnit handling Content-Type incorrectly
602
        if (getHeaderFieldDirect("Content-Type") == null) {
1✔
603
            setHeader("Content-Type", _contentType + "; charset=" + getCharacterEncoding());
1✔
604
        }
605
        _headersComplete = true;
1✔
606
    }
1✔
607

608
    /**
609
     * Adds the cookie header.
610
     */
611
    private void addCookieHeader() {
612
        if (_cookies.isEmpty()) {
1✔
613
            return;
1✔
614
        }
615

616
        StringBuilder sb = new StringBuilder();
1✔
617
        for (Enumeration e = Collections.enumeration(_cookies); e.hasMoreElements();) {
1✔
618
            Cookie cookie = (Cookie) e.nextElement();
1✔
619
            sb.append(cookie.getName()).append('=').append(cookie.getValue());
1✔
620
            if (cookie.getPath() != null) {
1!
621
                sb.append(";path=").append(cookie.getPath());
1✔
622
            }
623
            if (cookie.getDomain() != null) {
1!
624
                sb.append(";domain=").append(cookie.getDomain());
×
625
            }
626
            if (e.hasMoreElements()) {
1!
627
                sb.append(',');
×
628
            }
629
        }
1✔
630
        setHeader("Set-Cookie", sb.toString());
1✔
631
    }
1✔
632

633
    static {
634
        ENCODING_MAP.put("ISO-8859-1", "ca da de en es fi fr is it nl no pt sv ");
1✔
635
        ENCODING_MAP.put("ISO-8859-2", "cs hr hu pl ro sh sk sl sq ");
1✔
636
        ENCODING_MAP.put("ISO-8859-4", "et lt lv ");
1✔
637
        ENCODING_MAP.put("ISO-8859-5", "be bg mk ru sr uk ");
1✔
638
        ENCODING_MAP.put("ISO-8859-6", "ar ");
1✔
639
        ENCODING_MAP.put("ISO-8859-7", "el ");
1✔
640
        ENCODING_MAP.put("ISO-8859-8", "iw he ");
1✔
641
        ENCODING_MAP.put("ISO-8859-9", "tr ");
1✔
642

643
        ENCODING_MAP.put("Shift_JIS", "ja ");
1✔
644
        ENCODING_MAP.put("EUC-KR", "ko ");
1✔
645
        ENCODING_MAP.put("TIS-620", "th ");
1✔
646
        ENCODING_MAP.put("GB2312", "zh ");
1✔
647
        ENCODING_MAP.put("Big5", "zh_TW zh_HK ");
1✔
648
    }
1✔
649

650
    @Override
651
    public String getHeader(String name) {
652
        return (String) _headers.get(name.toUpperCase());
×
653
    }
654

655
    @Override
656
    public Collection<String> getHeaders(String name) {
657
        List values;
658
        synchronized (_headers) {
×
659
            values = (ArrayList) _headers.get(name.toUpperCase());
×
660
        }
×
661
        if (values == null) {
×
662
            return Collections.emptyList();
×
663
        }
664
        return values;
×
665
    }
666

667
    @Override
668
    public Collection<String> getHeaderNames() {
669
        if (!_headersComplete) {
×
670
            completeHeaders();
×
671
        }
672
        List names = new ArrayList<>();
×
673
        for (Enumeration e = _headers.keys(); e.hasMoreElements();) {
×
674
            names.add(e.nextElement());
×
675
        }
676
        return names;
×
677
    }
678

679
    @Override
680
    public void setContentLengthLong(long len) {
681
        setLongHeader("Content-Length", len);
×
682
    }
×
683

684
    public void sendRedirect(String location, int sc, boolean clearBuffer) throws IOException {
685
        setStatus(sc);
×
686
        setHeader("Location", location);
×
687
        if (clearBuffer) {
×
688
            resetBuffer();
×
689
        }
690
    }
×
691

692
}
693

694
class ServletUnitOutputStream extends ServletOutputStream {
695

696
    ServletUnitOutputStream(ByteArrayOutputStream stream) {
1✔
697
        _stream = stream;
1✔
698
    }
1✔
699

700
    @Override
701
    public void write(int aByte) throws IOException {
702
        _stream.write(aByte);
1✔
703
    }
1✔
704

705
    private ByteArrayOutputStream _stream;
706

707
    @Override
708
    public boolean isReady() {
709
        return false;
×
710
    }
711

712
    @Override
713
    public void setWriteListener(WriteListener writeListener) {
714
        // Do nothing
715
    }
×
716
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc