mirror of
				https://github.com/librenms/librenms.git
				synced 2024-10-07 16:52:45 +00:00 
			
		
		
		
	Updated sharp printer discovery and test unit
This commit is contained in:
		@@ -1538,7 +1538,7 @@ $config['os'][$os]['icon']             = 'ricoh';
 | 
			
		||||
$config['os'][$os]['over'][0]['graph'] = 'device_toner';
 | 
			
		||||
$config['os'][$os]['over'][0]['text']  = 'Toner';
 | 
			
		||||
 | 
			
		||||
$os = 'sharpprinter';
 | 
			
		||||
$os = 'sharp';
 | 
			
		||||
$config['os'][$os]['group']            = 'printer';
 | 
			
		||||
$config['os'][$os]['text']             = 'Sharp Printer';
 | 
			
		||||
$config['os'][$os]['type']             = 'printer';
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										6
									
								
								includes/discovery/os/sharp.inc.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								includes/discovery/os/sharp.inc.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,6 @@
 | 
			
		||||
<?php
 | 
			
		||||
if (!$os) {
 | 
			
		||||
    if (strstr($sysDescr, 'SHARP MX-')) {
 | 
			
		||||
        $os = 'sharp';
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
@@ -1,7 +0,0 @@
 | 
			
		||||
<?php
 | 
			
		||||
if (!$os) {
 | 
			
		||||
    // Sharp Multifunction Printer/Scanner
 | 
			
		||||
    if (strstr($sysDescr, 'SHARP MX-')) {
 | 
			
		||||
        $os = 'sharpprinter';
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
@@ -172,6 +172,13 @@ class DiscoveryTest extends \PHPUnit_Framework_TestCase
 | 
			
		||||
        $this->checkOS('qnap', 'Linux', '', $mockSnmp);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public function testSharp()
 | 
			
		||||
    {
 | 
			
		||||
        $this->checkOS('sharp', 'SHARP MX-2614N');
 | 
			
		||||
        $this->checkOS('sharp', 'SHARP MX-C301W');
 | 
			
		||||
        $this->checkOS('sharp', 'SHARP MX-3140N');
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public function testSophos()
 | 
			
		||||
    {
 | 
			
		||||
        $this->checkOS('sophos', 'Linux g56fa85e');
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user