!
! Author : J. Czechowski IV
! Version: $Id: test_sd360.mm,v 1.6 2011/04/02 17:23:41 crs Exp $
!
!  Macro for testing the FILE intrinsic when using an HTTP resource.
!
!  Dependencies:
!
startmacro l:sPort[9000]
  switch INTERACTIVE interAct GET DEF=TRUE
  
  set instructions "SD360 should be running in the top pane. The botton pane &
                    should show a copy of the _WAVEB raster plot from SD360. &
                    Do NOT click the 'Exit' button in SD360. You should see a &
                    logger in the sd360 macro with green INFO msg about the &
                    RMIF connection and timestamp."
  set waveb_url "http://localhost:^{sPort}/Files/RAM/_WAVEB"

  if interAct then
    info "%TEST_SD360: See %TEST_RMIF for RMIF tests."
    
    pipe on
      panel/msgid=MAIN/setup/controls=gc/panes=WIN
      gcontrol label macro "MACRO"
      gcontrol menu MAIN "Exit with Status =" "PASS,FAIL" TABLE={ItemColors={PASS="GREEN",FAIL="RED"}} /tleft

      gcontrol text idtext "INSTRUCTIONS" "^instructions" 24 12 /title
      
      sd360/bg/id="IDSD360"/server=^sPort/logger ! Logger added for Bug 1563
      plot/id="IDPLOT" "^waveb_url"
      set reg.WIN.idplot.title "^waveb_url"
      
    pipe off

  endif
  

endmacro

!******************************************************************************!
procedure processMessage m:msg
  if msg.name eqs "MAIN" then
    assert/text="SD360 tests" msg.data eqss "PASS"
    message SEND IDSD360 ,, "STATE" ,, "EXIT"
    pipe stop
  endif
return

