Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. redirecting console output from QTest to a widget or QString
QtWS25 Last Chance

redirecting console output from QTest to a widget or QString

Scheduled Pinned Locked Moved Unsolved General and Desktop
qteststdcout
7 Posts 3 Posters 3.8k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ck_eeC Offline
    ck_eeC Offline
    ck_ee
    wrote on last edited by
    #1

    Hi,

    i'd like to redirect the generated console text by QTest to somehwere else. Any hints or ideas?

    jsulmJ raven-worxR 2 Replies Last reply
    0
    • ck_eeC ck_ee

      Hi,

      i'd like to redirect the generated console text by QTest to somehwere else. Any hints or ideas?

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @ck_ee I don't understand the question. Do you want to write your own app where you use QTest and then show its output inside your app? If so you can start the tests in another process using QProcess and read its standard output (and standard error output) and insert the text in a text widget.

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      ck_eeC 1 Reply Last reply
      0
      • jsulmJ jsulm

        @ck_ee I don't understand the question. Do you want to write your own app where you use QTest and then show its output inside your app? If so you can start the tests in another process using QProcess and read its standard output (and standard error output) and insert the text in a text widget.

        ck_eeC Offline
        ck_eeC Offline
        ck_ee
        wrote on last edited by
        #3

        @jsulm i want one app where the QTest is executed and its console output should be printed in a widget. Starting another process just seems too complicated.

        jsulmJ 1 Reply Last reply
        0
        • ck_eeC ck_ee

          @jsulm i want one app where the QTest is executed and its console output should be printed in a widget. Starting another process just seems too complicated.

          jsulmJ Offline
          jsulmJ Offline
          jsulm
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @ck_ee See here http://blog.debao.me/2013/07/redirect-current-processs-stdout-to-a-widget-such-as-qtextedit/

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          ck_eeC 1 Reply Last reply
          0
          • jsulmJ jsulm

            @ck_ee See here http://blog.debao.me/2013/07/redirect-current-processs-stdout-to-a-widget-such-as-qtextedit/

            ck_eeC Offline
            ck_eeC Offline
            ck_ee
            wrote on last edited by
            #5

            @jsulm i'm looking for a plattform independent solution..

            jsulmJ 1 Reply Last reply
            0
            • ck_eeC ck_ee

              @jsulm i'm looking for a plattform independent solution..

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by
              #6

              @ck_ee I'm not aware off any plattform independent solutions for this

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              0
              • ck_eeC ck_ee

                Hi,

                i'd like to redirect the generated console text by QTest to somehwere else. Any hints or ideas?

                raven-worxR Offline
                raven-worxR Offline
                raven-worx
                Moderators
                wrote on last edited by raven-worx
                #7

                @ck_ee
                i don't think using a custom message-handler works, but worth a try.

                --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
                If you have a question please use the forum so others can benefit from the solution in the future

                1 Reply Last reply
                0

                • Login

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • Users
                • Groups
                • Search
                • Get Qt Extensions
                • Unsolved